python Connect Oracle Code of the database , Need to quote cx_Oracle library
#coding=UTF-8 import cx_Oracle def hello(): '''Hello cx_Oracle Example : 1) Print database version information . 2) Query table data .''' conn = cx_Oracle.connect("obs61","obs61","tx8i.hp") cur = conn.cursor() try: print "Oracle Version:%s" % conn.version print "Table SUB_POLICY rows:" cur.execute('select * from wlan_future_event') for row in cur: print row finally: cur.close() conn.close() hello()