How to correctly sync database with Askbot app?

asked 2012-07-15 16:41:14 -0600

Louis-Philippe gravatar image


I followed the tutorial on installing Askbot:

When I run "python 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 migrate askbot
  • python 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

edit retag flag offensive close merge delete


Please give details about your database and version. Also you could try:

python syncdb --all --noinput
python migrate --fake

And then, if you are on postgresql:

python init_postgresql_full_text_search
Evgeny gravatar imageEvgeny ( 2012-07-15 16:44:34 -0600 )edit

Which version of MySQL are you on? My postgres comments won't help you.

Evgeny gravatar imageEvgeny ( 2012-07-16 22:44:06 -0600 )edit

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.

Louis-Philippe gravatar imageLouis-Philippe ( 2012-07-16 22:45:30 -0600 )edit

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.

Evgeny gravatar imageEvgeny ( 2012-07-16 22:48:17 -0600 )edit

The database client version is libmysql - mysqlnd 5.0.8-dev - 20102224 - $Revision: 321634$

Louis-Philippe gravatar imageLouis-Philippe ( 2012-07-16 22:49:32 -0600 )edit