My
vb code in my asp file successfully connects to a database I just set up and for which I created a DSN. But the SELECT query says Invalid object name MyTable:
Code:
Dim oConn
Dim oRS
Dim strSQL
Dim dt
Set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open dbString
strSQL = "SELECT MyCol FROM MyTable WHERE MyOtherCol = '" & 1 & "'"
Set oRS = oConn.Execute (strSQL)
The object/table definitely exists. I can open it in Query Analyzer. Any idea? Permission problem, maybe?
Thanks.