I want to export and export only the Categories and their description using SQL. For now I've managed to retrieve them using this:

FROM wp_term_taxonomy
    JOIN wp_terms ON ( wp_term_taxonomy.term_id = wp_terms.term_id )
WHERE wp_term_taxonomy.taxonomy = 'category'

I need some advices on how do to this so I can not screw up the blog. I mention that on the new blog I do not have these categories.

2 Answers 2


How about just backing up those two tables using phpMyAdmin as detailed in the codex article on wordpress backups?


The best solution is to setup a backup routine for your SQL database which I maintain.

Using DBC Backup 2 you can setup a schedule and trigger a manual backup anytime you like. This way you can then muck around with categories or posts or other settings and have the confidence you can use your SQL backup if needed

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.