Timeline for Order posts by (hierarchical custom) taxonomy terms and term children
Current License: CC BY-SA 3.0
8 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Oct 16, 2012 at 14:34 | vote | accept | kaiser | ||
Oct 15, 2012 at 20:07 | history | edited | kaiser | CC BY-SA 3.0 |
edited title
|
Oct 15, 2012 at 18:14 | answer | added | marfarma | timeline score: 3 | |
Oct 15, 2012 at 17:17 | comment | added | marfarma | If I had some real data to play with, I could work out the SQL -- lets continue to discuss in chat | |
Oct 15, 2012 at 17:12 | comment | added | kaiser | @marfarma Would you be able to add an answer? :) | |
Oct 15, 2012 at 17:01 | comment | added | marfarma | Once you have all the leaf nodes, you'd add an outer join to pick up the parent taxons. Calculate column order_term = is_null(parent, child) and order by order_term | |
Oct 15, 2012 at 16:57 | comment | added | marfarma | First thing - work out the SQL query you'd need to do this. I see a recursive self-join of wp_term_taxonomy in your future. Thinking out loud, the query can only return a list of posts -- and you only want each post to appear once at it's leaf taxon level. Something like this: SO: recursive self join SQL | |
Oct 15, 2012 at 16:32 | history | asked | kaiser | CC BY-SA 3.0 |