You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When we use Freetds and unixodbc with pyodbc-azure package in our Django application , we are getting the error while connecting to MSSql Server 2016
django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
Could the issue be the TDS version used? According to this FreeTDS page you need to be using TDS version 7.3 and above in order to support DATETIME2, etc. I have not tested it, but it may be worth trying the following:
'OPTIONS': {
'host_is_server': True,
'unicode_results': True,
'driver': 'FreeTDS',
'extra_params': "TDS_VERSION=7.3", # force the TDS version to 7.3 or 7.4 or 8.0
},
When we use Freetds and unixodbc with pyodbc-azure package in our Django application , we are getting the error while connecting to MSSql Server 2016
django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
Our settings.py is as follows
DATABASES = {
'default': {
'ENGINE': 'sql_server.pyodbc',
'NAME': 'quickstartdb',
'USER': 'xx',
'PASSWORD': 'password',
'HOST': '192.xxx.xx.xx',
'PORT': '1433',
'OPTIONS': {
# 'AUTOCOMMIT': True,
'host_is_server': True,
'unicode_results': True,
'driver': 'FreeTDS',
},
},
}
Our ubuntu version is 18.10
The text was updated successfully, but these errors were encountered: