Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error Invoking SQL SP from Access

Status
Not open for further replies.

btturner

Programmer
May 17, 2001
175
US
Receiving error msg when attempting to invoke a SQL Stored Procedure, from Access form, using a hard-coded UserID: Dom1\SQLDBA (domain\userid)

INVALID CONNECTION STRING ATTRIBUTE
Login failed for userid: Dom1\SQLDBA. Reason: Not associated w/ a trusted SQL Server conection.
--> (fyi, Dom1\SQLDBA is sysadm on the box)

here's the code:

strConnect = "ODBC" & "DSN= " & lsDev & _
";DRIVER=SQL Server" & _
";UID=" & "Dom1\SQLDBA" & _
";PWD=" & "pQrStUv" & _
";DATABASE=" & "DB_Prod" & _
";SERVER=" & "ProdServer1" & _
";LOGINTIMEOUT=50000" & _
";ODBCTimeout = 50000"


this next set of code (w/out a Userid/Pwd) works fine:

strConnect = "ODBC" & "DSN= " & lsDev & _
";DRIVER=SQL Server" & _
";UID=" & _
";PWD=" & _
";DATABASE=" & "DB_Prod" & _
";SERVER=" & "ProdServer1" & _
";LOGINTIMEOUT=50000" & _
";ODBCTimeout = 50000"
 
I have a feeling that vba is having a problem with the \...

Try coding that a little different... If that's not it, I have no idea's...

--James
junior1544@jmjpc.net
Life is change. To deny change is to deny life.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top