<%
dim conn,strcon
set conn=server.createobject("adodb.connection")
strcon = "PROVIDER=MSDASQL;"
strcon = strcon & "DRIVER={Microsoft Access Driver (*.mdb)};"
strcon = strcon & "DBQ=" & Server.mappath("alt.mdb")&";"
conn.open=strcon
%>
I used the following modifications to connect to the new SQL 2005 db:
<%
dim conn,strcon
set conn=server.createobject("adodb.connection")
strcon =
"PROVIDER=SQLOLEDB;SERVER=00.000.000.000;UID=user;PWD=password;DATABASE=ALT;"
conn.open=strcon
%>
When I try to connect, it waits a bit then errors. Any other changes and it
errors immediately, so I think I'm close.
Any suggestions?
--
Erland Sommarskog, SQL Server MVP, esq...@sommarskog.se
Links for SQL Server Books Online:
SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Well, what I know now is that you use this connection string:
PROVIDER=SQLOLEDB;SERVER=00.000.000.000;UID=user;PWD=password;DATABASE=ALT;
Where the zeroes is probably a placeholder for an IP-adress. And I know
this:
>>> When I try to connect, it waits a bit then errors. Any other changes
>>> and it errors immediately, so I think I'm close.
I'm afraid that is very little information to work with, so don't expect
any bright answers. Bear in mind that solving connection issues require
knowledge about your local environment, about which I know nada.
Anyway, with the above you say that it errors after waiting a while.
By chance, you don't happen to be willing to share the error message?
When it errors directly what error message do you get?
The fact that it waits, indicate you are not specifying the correct
server. That is, there is no server on that IP-address, or it is
not listening on port 1433. Or there is a server, but it is not accepting
remote connections. Or it is not running.
--
__________________________________________________________________________
William R. Vaughn
President and Founder Beta V Corporation
Author, Mentor, Dad, Grandpa
Microsoft MVP
(425) 556-9205 (Pacific time)
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
http://betav.com http://betav.com/blog/billva
____________________________________________________________________________________________
"Erland Sommarskog" <esq...@sommarskog.se> wrote in message
news:Xns9C9DF1C7D...@127.0.0.1...