Django officially supports these databases: PostgreSQL, MariaDB, MySQL, Oracle, SQLite.
Connect django project with MySQL.
In settings.py write this
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': 'link_verse_db',
'USER': 'user_name',
'PASSWORD': 'password',
'HOST': 'localhost', # Use '127.0.0.1' if you have issues with 'localhost'
'PORT': '3306', # MySQL default port
}
}
My requirement was to connect to MySQL and also to be able to see all the models (tables) including Django's build in models on workbench.
Comments
Post a Comment