4

Does anyone know how to use the django-mssql provider? I've installed the requirements but I cannot get it to work.

Without sqlserver_ado in settings.py it imports fine:

(testenv) C:\Users\Robin\test>python manage.py shell
Python 2.7.2 (default, Jun 12 2011, 14:24:46) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> import sqlserver_ado
>>> ^Z

With a database set to use sqlserver_ado in settings.py:

(testenv) C:\Users\Robin\test>python manage.py shell
ImproperlyConfigured: 'sqlserver_ado' isn't an available database backend.
Try using 'django.db.backends.XXX', where XXX is one of:
    u'mysql', u'oracle', u'postgresql_psycopg2', u'sqlite3'
Error was: cannot import name InterfaceError

EDIT:

Django==1.5 django-mssql==1.5b1

EDIT 2:

Browsing the source for django-mssql reveals that it's trying to import InterfaceError from django.db.utils which doesn't exist in Django 1.5

1
  • 2
    What version of Django are you using, and what's the version of the django-mssql module? Commented Feb 20, 2014 at 13:07

1 Answer 1

4

It's mentioned on the project's Bitbucket page at https://bitbucket.org/Manfre/django-mssql/overview that:

"The current version of django-mssql supports Django 1.6. If using an older version of Django, you will need to use an earlier version of django-mssql.

django-mssql 1.4 supports Django 1.4 and 1.5."

I installed 1.4 and now I just need to get the provider working.

Sign up to request clarification or add additional context in comments.

2 Comments

and what about django 1.8.1? can you please tell me which version of djonago-mssql is suitable?
@HarshaBiyani I've just had a look at the project page and it seems the latest django-mssql is 1.7 which supports Django 1.7. Looking at the commits to master it would appear that a 1.8 compatible version is in development.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.