For Connection python to Oracle use cx_Oracle. cx Oracle is a Python extension module thats allows access to Oracle Databases and conforms to the Python Database API specification. This module is currently built against Oracle 9.2.0, 10.2.0 and 11.1.0.
The interface specification consists of several sections:
- Module Interface
- Connection Objects
- Cursor Object
- Type Object and Constructors
- Implementattion Hints for Module Authors
- Optional DB API Extensions
- Optional Error Handling Extensions
- Optional Two-Phase Commit Extensions
- Frequently Asked Questions
- Major Changes from version 1.0 to Version 2.0
- Open Issues
- Footnotes
- Unknowledgements
for Excample use cx_Oracle :
import sys, cx_Oraclegood luck,.......
connect=cx_Oracle.Connection("system/password@Server_database")
cursor=connect.cursor()
cursor.execute("PL/SQL or Query language")
data=cursor.fetchall()
data in method list, but can for print such as looping
for (list fields) in data:
print list fields
No comments:
Post a Comment