How to correctly sync database with Askbot app?
Hi,
I followed the tutorial on installing Askbot:
http://askbot.org/doc/initialize-database-tables.html
When I run "python manage.py syncdb", I get the following message in my terminal:
Not synced (use migrations): - askbot.deps.django_authopenid - askbot
I then ran the two following commands:
- python manage.py migrate askbot
- python manage.py migrate django_authopenid
But my tables are not up to date. If I try to login in my local Askbot web application, I get an error message saying "Unknown column 'askbot_anonymousanswer.question_id".
Looking at this table in MySQL, the field is named "question_post_id". My feeling is that Askbot hasn't created the right database schema.
But I don't know any alternative. Does somebody know what I did wrong? How do I know the database version is sync with the application? I couldn't find a table with the database version.
Thanks for your help
Comments
Please give details about your database and version. Also you could try:
And then, if you are on postgresql:
Which version of MySQL are you on? My postgres comments won't help you.
Thanks Evgeny for the fast answer. Unfortunately, it did not work. I'm using the community edition of MySQL. It's version is 5.5.25a. Sorry for the multiple comments. Each time I press the Enter key, it posts the comment to Askbot.
In which migration do you get error? Please post traceback into your question. Also I can recommend switching to MyISAM storage engine. In the case you are using InnoDB, askbot will not work, because search relies on the MyISAM feature. Yes, enter key auto-posts the comment, try "shift enter" to add empty lines.
The database client version is libmysql - mysqlnd 5.0.8-dev - 20102224 - $Revision: 321634$