05-24-2011, 02:27 PM
I am using below and i am able to getdata from oracle.we need to have oracle installed in the machine to run this
Code:
Dim sDataSource
sDataSource = envDBInstance
Dim strConnection, oDbConn, rs, strSQL
strConnection = "Provider=OraOLEDB.Oracle;Data Source=" & sDataSource & ";User Id=user;Password=password;"
on Error Resume Next
Set oDbConn = CreateObject("ADODB.Connection")
oDbConn.Open strConnection
Set oResultSet = CreateObject("ADODB.recordset")
oResultSet.open sQuery, oDbConn, 3,3