Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Traceback (most recent call last):
- File "/Library/Python/2.7/site-packages/django/utils/autoreload.py", line 226, in wrapper
- fn(*args, **kwargs)
- File "/Library/Python/2.7/site-packages/django/core/management/commands/runserver.py", line 116, in inner_run
- self.check(display_num_errors=True)
- File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 426, in check
- include_deployment_checks=include_deployment_checks,
- File "/Library/Python/2.7/site-packages/django/core/checks/registry.py", line 75, in run_checks
- new_errors = check(app_configs=app_configs)
- File "/Library/Python/2.7/site-packages/django/core/checks/model_checks.py", line 28, in check_all_models
- errors.extend(model.check(**kwargs))
- File "/Library/Python/2.7/site-packages/django/db/models/base.py", line 1172, in check
- errors.extend(cls._check_long_column_names())
- File "/Library/Python/2.7/site-packages/django/db/models/base.py", line 1587, in _check_long_column_names
- connection = connections[db]
- File "/Library/Python/2.7/site-packages/django/db/utils.py", line 212, in
- __getitem__
- backend = load_backend(db['ENGINE'])
- File "/Library/Python/2.7/site-packages/django/db/utils.py", line 135, in load_backend
- raise ImproperlyConfigured(error_msg) django.core.exceptions.ImproperlyConfigured: 'sql_server.pyodbc' isn't an available database backend. Try using 'django.db.backends.XXX', where XXX is one of:
- 'mysql', 'oracle', 'postgresql', 'sqlite3'
- Error was: No module named sql_server.pyodbc.base
- mysql> SHOW DATABASES;
- +--------------------+
- | Database |
- +--------------------+
- | information_schema |
- | mysql |
- | performance_schema |
- | mydb |
- | sys |
- +--------------------+
- 5 rows in set (0.00 sec)
- DATABASES = {
- 'default': {
- 'ENGINE': 'django.db.backends.mysql',
- 'NAME': 'mydb',
- 'USER': 'dbuser',
- 'PASSWORD': 'dbpassword',
- 'HOST': '127.0.0.1',
- 'PORT': '3306',
- 'OPTIONS' : {
- 'sql_mode': 'ANSI',
- "init_command": "SET foreign_key_checks = 0;"},
- },
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement