Same thing happened to me, problem was that my database was not properly configured with a temp directory, maybe yours is the same or disk space ???
See http://wordpress.org/support/topic/problem-with-categories-6?replies=2
OK, I’ve resolved this. It was my database configuration that was incorrect. Thanks to this blog http://mingfai.ma/2010/08/28/wordpress-categories-tags-not-working-explained/ I tried to play around with some SQL and came up with this
SELECT *
FROM wp_terms t
left join wp_term_taxonomy w
on t.term_id = w.term_id and taxonomy=’category’
left join wp_term_relationships r
on w.term_taxonomy_id = r.term_taxonomy_id
left join wp_posts p
on r.object_id = p.id
Which showed my posts with the categories (I’m using mysql Query browser) but when I added an order clause at the end (order by r.object_id) it did not work.
There was an issue with my temporary directory. I changed the my.ini file (found at C:\Program Files\MySQL\MySQL Server 4.1) to include the line tmpdir=C:/temp
Everything now works.