Ever wanted a listing of all your posts along with which categories they are in? Want it in SQL outside of WordPress? Then use this code -
select wpr.object_id, wp_terms.name from wp_terms inner join wp_term_taxonomy on wp_terms.term_id = wp_term_taxonomy.term_id inner join wp_term_relationships wpr on wpr.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id where taxonomy= "category" order by object_id;
Or for a more expansive version with better clarity -
select p.post_title, wpr.object_id, wp_terms.name from wp_terms inner join wp_term_taxonomy on wp_terms.term_id = wp_term_taxonomy.term_id inner join wp_term_relationships wpr on wpr.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id inner join wp_posts p on p.ID = wpr.object_id where taxonomy= "category" and p.post_type = 'post' order by object_id;
There you have it. Point that through your favourite sql code runner, and be amazed by the results…

There are 5 comments on this entry -
Thanks,
For all the inputs on the WP forum. I’ll post you the results once the 3D layers are populate from the cms.
Arg..
Im stuck in a new problem with search form phpMyAdmin
http://wordpress.org/support/topic/237497
Any idea?
Hi,
Ive made a workaround.
http://wordpress.org/support/topic/237497
cheers!
For all the inputs on the WP forum. I’ll post you the results once
this is real comment and thanks for all things