Questions tagged [django-pyodbc-azure]

This is a deprecated tag for a Python package that is no longer maintained.

The django-pyodbc-azure package is no longer maintained.

Please use django-mssql-backend instead; it supports Django 2.2 and above.

49 questions
2
votes
1 answer

Can't connect to MSSQL using django-pyodbc-azure 2.1.0.0

As the title says. Im getting this error django.db.utils.InterfaceError: ('IM002', '[IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified (0) (SQLDriverConnect)') Heres my code DATABASES = { 'default':…
Dan Sto Domingo
  • 64
  • 1
  • 11
2
votes
1 answer

Django Hive connectivity

DATABASES = { 'default': { 'ENGINE': 'sql_server.pyodbc', 'NAME': 'sampletest', 'OPTIONS': { 'driver': '/opt/cloudera/hiveodbc/lib/64/libclouderahiveodbc64.so', 'dsn': 'Hive1', …
Ripundeep Gill
  • 231
  • 5
  • 18
2
votes
2 answers

How to set up Django Azure website to access database

I am trying to set up my Django site using Azure Websites (not an Azure VM). I got a site with some static pages up and running, and I created an Azure SQL Database, but how do I connect the Django site to use the Azure db?
Hat
  • 1,691
  • 6
  • 28
  • 44
1
vote
1 answer

Can't open lib 'ODBC Driver 17 for SQL Server' : file not found (0) (SQLDriverConnect)") on Azure Linux

I'm trying to deploy python django app on azure linux using azure cli and after deployment it is showing me database connectivity error for drivers. The error message is: Can't open lib 'ODBC Driver 17 for SQL Server' : file not found…
Kaushik
  • 11
  • 1
  • 2
1
vote
2 answers

Parameterized raw sql query much slower than query with actual values

I am trying to execute a raw sql query with connections[].cursor() in a Django app that connects to SQL server. The query executes much faster (<1s) when I provide the actual vlaues in the query string. from django.db import connections with…
Bellatrix
  • 29
  • 1
  • 8
1
vote
1 answer

Why isn't Django connecting to SQL Server 2019?

Please see below screenshots as to existing configuration (password hidden due to security reasons). Databases Screenshot 1 Python Packages The error that is returned when I attempt to run the server is either SQL Server v15 is not supported or…
1
vote
1 answer

with transaction.atomic() not working for Azure SQL Database

I use django-pyodbc-azure 2.1.0.0 for the connection with an Azure SQL database which works fine. When I understand the documentation of django-pyodbc-azure correctly, transactions should be supported. However, this code immediately updates the row.…
RaideR
  • 869
  • 1
  • 12
  • 33
1
vote
0 answers

CANNOT connect to SQL Server from Django on Heroku

My website will just load an existing table (brand) from SQL server and display to index page. I'm able to run the website on my machine without any problem, but it seems like the table doesn't exist when I deploy the project to Heroku. (The deploy…
Lazywii
  • 133
  • 1
  • 7
1
vote
1 answer

Django 2.0+ and SQL Server interface question

Why is it necessary to have both Pyodbc and django-pyodbc-azure installed to interface with recent SQL Server versions with Django? Why can't django just use Pyodbc out of the box? I'm having trouble getting Sql Server to play nice with python…
Jasonca1
  • 4,848
  • 6
  • 25
  • 42
1
vote
1 answer

Connecting to a legacy informix database with django

I'm trying to connect to an existing Informix database with Django, I'm using django-pyodbc-azure to handle the connection via odbc, the connection work fine when trying in the python interpreter: >>>import pyodbc >>>conn =…
1
vote
3 answers

django-pyodbc-azure no module named 'sql_server'

I am attempting to use a corporate SQL Server as the backend for my Django project with Python 3.5.2. I have installed Django 2.0.3, pyodbc==4.0.22, django-pyodbc-azure 2.0.3, pypiwin32==219 (pip freeze below). I have also configured DATABASES in my…
1
vote
1 answer

Introspection Bug - Looks for django_migrations at the Database Level Instead of Schema Level

Update 6: After discussing the issue on the IRC #django, I think django-pyodbc-azure is introspecting the database and looking for django_migrations at the database level, not the schema level. Therefore, it's finding it at the database level (from…
1
vote
0 answers

By adding one statement import pyodbc causes Internal Server Error in Apache HTTP Server

To run the normal school old python file in Apache Server. I had coded this way index.html
First Name:
Last Name:
1
vote
1 answer

Django create a Datatable using MSSQL

Hello I am new to using Django and would like to create a datatable with data that is stored in a database of an MSSQL server. I have managed to connect Django via django_mssql but I do not know how to access a table since there are many in the…
1
vote
1 answer

Update to pyodbc 4 causes "Segmentation fault"

I have a Django+celery site running on Elastic Beanstalk that used pyodbc 3. Because of another issue, I had to update to pyodbc 4. However, the web site starting giving error 500 and this is the information logged: [Fri Feb 24 20:02:14.448536…
Diego Jancic
  • 7,280
  • 7
  • 52
  • 80