加入python部分脚本

This commit is contained in:
2020-11-23 17:47:48 +08:00
parent 6b8cfe2c98
commit cd259de06a
6 changed files with 76 additions and 2 deletions

View File

@@ -0,0 +1,25 @@

import sys;
import cx_Oracle;
def getConnectString( user_name, password, db_name ):
return userName + "/" + password + "@" + dbName
sql = \
"select * \n" \
" from idst0.rydm_t"
userName = "dataex"
password = "cpic123456"
dbName = "10.39.0.86/xmcx1"
conn = cx_Oracle.connect( getConnectString(userName,password,dbName) )
curs = conn.cursor()
result = curs.execute(sql)
row = curs.fetchone()
print( row )
curs.close()
conn.close()

View File

@@ -4,7 +4,7 @@
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>81f2541e-c96a-4c05-b3f5-643b25e708d5</ProjectGuid>
<ProjectHome>.</ProjectHome>
<StartupFile>RepairOrderScrap\RepairOrderScrap.py</StartupFile>
<StartupFile>DataManagement\CarDealer.py</StartupFile>
<SearchPath>
</SearchPath>
<WorkingDirectory>.</WorkingDirectory>
@@ -22,9 +22,12 @@
<EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
</PropertyGroup>
<ItemGroup>
<Folder Include="DataManagement\" />
<Folder Include="RepairOrderScrap\" />
</ItemGroup>
<ItemGroup>
<Compile Include="DataManagement\CarDealer.py" />
<Compile Include="DataManagement\__init__.py" />
<Compile Include="RepairOrderScrap\RepairOrderScrap.py">
<SubType>Code</SubType>
</Compile>