Set objConDotnet=DotNetFactory.CreateInstance("System.Data.Odbc.OdbcConnection","System.Data")
'objConDotnet.ConnectionString="Server=xxx; UID=yyy; DataBase=zzz"
strCon="DRIVER={Microsoft ODBC for Oracle};SERVER=XXX; UID=YYY; PWD=ZZZ"
objConDotnet.ConnectionString=strCon
Print objConDotnet.ConnectionString
Print TypeName(objConDotnet)
objConDotnet.ConnectionTimeOut=0
objConDotnet.Open()
Print Cstr(objConDotnet.State)
strSql= "Select Count(*) from
Set objCmdDotnet=DotNetFactory.CreateInstance("System.Data.Odbc.OdbcCommand","System.Data")
objCmdDotnet.CommandText=strSql
objCmdDotnet.Connection= objConDotnet
strValue = objCmdDotnet.ExecuteScalar()
Print "The return Count is : " & CInt(strValue)
objConDotnet.Close()
Print Cstr(objConDotnet.State)
2 comments:
I want to implement a system which can search and retrieve the matched info form a database which will have more then 50 million records as fast as possible. STC Technologies
You can create a new dataset/datatable and update the matched records in that and show for future manipulations. Ofcourse there are many other ways to do based on the requirements.
Post a Comment