Adding a database to the Django Project using Sqlite3 with Python 2.7

前端 未结 2 591
孤独总比滥情好
孤独总比滥情好 2020-12-16 03:16

I am trying to add a database to the Django Project using Sqlite3 and Python 2.7.

This is how my setting.py looks like:

DATABASES = {
    \'default\         


        
2条回答
  •  情深已故
    2020-12-16 03:55

    Type this before you execute the python manage.py syncdb

    export LC_CTYPE=en_US.UTF-8
    export LC_ALL=en_US.UTF-8
    

    This will solve the error.. Btw i was using mac os x python which was in /usr/bin/python.

    Add it to the ./.bash_profile file so that it calls it automatically..

提交回复
热议问题