Django officially supports the following databases:
There are also a number of database backends provided by third parties.
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql',
'NAME': "数据库名称",
'USER': "root",
'PASSWORD': "woailyoo",
'HOST': "192.168.247.5",
'PORT': '3306',
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
}
}
}
DATABASES = { 'default': { 'ENGINE': 'django.db.backends.oracle', 'NAME': '实例名', 'USER': 'a_user', 'PASSWORD': 'a_password', 'HOST': 'dbprod01ned.mycompany.com', 'PORT': '1540', } }