Solved

use mssql with django

Posted on 2014-02-21
12
160 Views
Last Modified: 2014-03-02
i'm brand new - still installing

how do i "install" the ability to use an mssql db?
0
Comment
Question by:dgrafx
  • 7
  • 5
12 Comments
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39877447
You would apparently have to write your own interface code because it is not one of the 'supported' databases.  https://docs.djangoproject.com/en/1.6/topics/install/#database-installation

Looks like someone else may have already done that:  http://django-mssql.readthedocs.org/en/latest/
0
 
LVL 25

Author Comment

by:dgrafx
ID: 39877468
thanks Dave - will check it out
0
 
LVL 25

Author Comment

by:dgrafx
ID: 39877482
Dave - earlier before you posted I was reading the docs and came across code like this:
DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.sqlite3',
        'NAME': 'mydatabase'
    }
}

WHERE can i find this code?
Is this a python file? extension of .py?
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39877668
SQLite comes with Django.  See here for more info: https://docs.djangoproject.com/en/1.6/ref/settings/#std:setting-DATABASES
0
 
LVL 25

Author Comment

by:dgrafx
ID: 39877834
Dave
What i mean is where are the files that code like this is in?
They appear to be config files - where are they?

I didn't mean what is SQlite.

as i said in the beginning i am brand new to django and also python.
i don't know anything.
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39877906
Then you need to first go thru the installation procedure and then do the tutorial.  There is too much to answer here and the docs are your best friend for this.

https://docs.djangoproject.com/en/1.6/intro/install/

https://docs.djangoproject.com/en/1.6/intro/tutorial01/
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 25

Author Comment

by:dgrafx
ID: 39877949
Dave
I have Django 1.7 & Python 3.3 installed already.

What I'm doing now is asking questions where I'm having difficulty.
I already have link to online docs ...
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39878166
The install instructions and the tutorial answer the questions you've asked so far including where to put the files and where that database directive goes.  I even found the 'alternate' database info there when I looked again.  You should install and run the tutorial to get a better understanding.
0
 
LVL 25

Accepted Solution

by:
dgrafx earned 0 total points
ID: 39887475
The problem was that the 3.x versions of Python don't seem to work with the Django-mssql package.
And since I am a complete newb I didn't know what I was doing wrong or what instructions I was misreading.
So I uninstalled and started from scratch using Python 2.7 and zero issues getting everything installed - distribute - pip - django - mssql
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 39887542
Good for you, glad you figured it out.
0
 
LVL 25

Author Comment

by:dgrafx
ID: 39887545
thanks Dave
0
 
LVL 25

Author Closing Comment

by:dgrafx
ID: 39898369
This is the solution to why I couldn't get mssql installed
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Installing Python 2.7.3 version on Windows operating system For installing Python first we need to download Python's latest version from URL" www.python.org " You can also get information on Python scripting language from the above mentioned we…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
Learn the basics of if, else, and elif statements in Python 2.7. Use "if" statements to test a specified condition.: The structure of an if statement is as follows: (CODE) Use "else" statements to allow the execution of an alternative, if the …
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…

948 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now