Problems with Django connecting to Oracle

Source: Internet
Author: User

Version information at start:

Python 3.6 + ce_oracle 6

Final version information:

Python 3.5 + ce_oracle 5.2

Ce_oracle version Issue

cx_oracle-5.2.1-12c.win-amd64-py3.5 5.2.1 refers to the cx_oracle version, 12c refers to the version of Oracle, and py3.5 refers to the version of Python

1. The installation started with Cx_oracle 6, but when running under Django, an error

    

Django.db.utils.databaseerror:ora-28009:connection as SYS should be as SYSDBA or sysoper

Google for a moment to find out why

Reason: The SYS user cannot be used when using Django to connect to Oracle, the SYS login must be logged in using the SYSDBA role, so you need to use a different user, I created a new user myself and then solved the problem

2. Try to run the program again, error:

Attributeerror: ' Cx_oracle.cursor ' object has no attribute ' numbersasstrings '

Find out after searching the website

The Numberasstrings property is no longer used for versions starting at 5.3, so try using version 5.2

However, it has been found that the use of python3.6 has been supported since 5.3

So uninstall the python3.6 on this machine.

Re-installing Python 3.5

Problem Solving!!!

Problems with Django connecting to Oracle

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.