Mmm... if you do a search on that error you will see lots of tracker reports and forum posts. I didn't read them all but they do seem to relate to sites being upgraded from 1.9. I suspect the origin of your problems lie there.
Is this a test? Can you roll back? If you didn't, I would make sure you started from the very latest 1.9 and also verify that the database schema is correct (http://docs.moodle.org/23/en/Verify_Database_Schema). This can cause all manner of oddness.