WebFaction
Community site: login faq

I installed django 1.11 with python 3.6. I also changed the default database settings (django_folder/myproject/settings.py) to use a postgresql database that I had already created. I then created the superuser (which successfully showed up in the postresql database). When I go to the admin page and try to login I get an error that the database tables don't exist and refers to the sqlite3 module throwing the error.

I tested creating an app with a model which correctly went to the postgresql database. Is there something I'm missing?

asked 04 May, 21:10

bohemian's gravatar image

bohemian
111
accept rate: 0%

So I ended up solving this on my own. The tutorial I was following didn't have the full information on what I needed to get django to talk to the database. The tutorial I was following said to change the database engine (in the settings.py file of myproject) to 'django.db.backends.postgresql'. It really needed to be 'django.db.backends.postgresql_psycopg2'

(04 May, 23:18) bohemian bohemian's gravatar image
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×30
×1

question asked: 04 May, 21:10

question was seen: 460 times

last updated: 04 May, 23:18

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2016 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM