Hi,
I have a form establishes an ADO DSN-less connection to an oracle database (I hope I said that right). I can successfully make the connection, but I need a little help getting the records to a table within my Access database. The table on the database changes hourly so I want the capability to use the form button to update my Access table whenever desired. I assume we'll either use a record set or some sort of SQL statement? If anybody has some code they could direct me to I would appreciate it.
I'll post what I have so far:
I have a form establishes an ADO DSN-less connection to an oracle database (I hope I said that right). I can successfully make the connection, but I need a little help getting the records to a table within my Access database. The table on the database changes hourly so I want the capability to use the form button to update my Access table whenever desired. I assume we'll either use a record set or some sort of SQL statement? If anybody has some code they could direct me to I would appreciate it.
I'll post what I have so far:
Code:
Private Sub cmdGetData_Click()
Dim conn As String
Dim cn As ADODB.Connection
Dim strSQL As String
conn = "UID= myID;PWD=myPW;DRIVER={Microsoft ODBC for Oracle};SERVER=myServer;"
Set cn = New ADODB.Connection
With cn
.ConnectionString = conn
.CursorLocation = adUseClient
.Open
End With