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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problems Connecting to ODBC Database.

Status
Not open for further replies.

ctau

IS-IT--Management
Feb 8, 2000
34
0
0
US
I am having problems connecting to an ODBC database. I am using the following code

Set MyConnection = Server.CreateObject("ADODB.Connection")
MyConnection.Open SQL, "dsn = wacs"


I get the following error when I run this. Line 31 is the DSN line.

___________________________________________________________
Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

/intranet/WACS_Customer.asp, line 31

____________________________________________________________

Thanks for the Help

Ctau
 
Have you created the ODBC DSN for SQL yet? The error seems like you haven't assigned the DSN. Also, the command should be:
Set MyConnection = Server.CreateObject("ADODB.Connection")
MyConnection.Open "DSN= = yourDSN; DataBase = yourDB"

Hope it helps


GH
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top