import cx_Oracle
sql="select * from vpx_version"
conn = cx_Oracle.connect('vcadmin/password@orcl')
cursor = conn.cursor()
cursor.execute(sql)
print conn.version
print ()
#for result in cursor:
# print result
res=cursor.fetchmany(numRows=3)
print res
conn.close
No comments:
Post a Comment