IamCornholio
Programmer
I'm trying to run a query that pushes to an oracle table. Since Access tends to hold onto its initial connection string, the string for the table I'm pushing to doesn't get refreshed and the permissions reset (changes UID and PWD to give me Update/Insert priveledges).
My code is:
[blue]
Dim db As Database
Dim LSProc As QueryDef
Dim strSQL As String
strSQL = "Insert Query Goes here"
Set db = CurrentDb()
Set LSProc = db.CreateQueryDef("")
LSProc.Connect= "xx-Copied connection string from table properties-xx"
LSProc.ReturnsRecords = False
LSProc.SQL = strSQL
LSProc.Execute
Set LSProc = Nothing
[/blue]
My code is:
[blue]
Dim db As Database
Dim LSProc As QueryDef
Dim strSQL As String
strSQL = "Insert Query Goes here"
Set db = CurrentDb()
Set LSProc = db.CreateQueryDef("")
LSProc.Connect= "xx-Copied connection string from table properties-xx"
LSProc.ReturnsRecords = False
LSProc.SQL = strSQL
LSProc.Execute
Set LSProc = Nothing
[/blue]