Re: Django 1.9.8 with mysql 'Commands out of sync; you can't run this command now' exception

2018-09-23 Thread Adolfo Cueto
. I know your code is the best practice but are > you sure your code will solve the problem? > > On Monday, September 24, 2018 at 11:13:14 AM UTC+7, Adolfo Cueto wrote: >> >> Hey man try to change you code line like this >> >> latest_message = >> Messag

Re: Django 1.9.8 with mysql 'Commands out of sync; you can't run this command now' exception

2018-09-23 Thread Adolfo Cueto
Hey man try to change you code line like this latest_message = Message.objects.filter(example_field=1).order_by("-id").first() El dom., 23 sept. 2018 a las 22:55, escribió: > I am a python developer and I am using Django 1.9.8 for my project. > I am having a problem with MySQL like below:

Re: Error at OneToOneField in models while creating new models class

2018-09-23 Thread Adolfo Cueto
First you have to change your model name Class names starts with uppercase... My friend.. you are not making migrations... look at you have to do this: 1. Delete your migration folder 2. Delete you app table manually (DROP table) 3. python manage.py makemigrations app_name 4. migrate that's