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!

Connection string is Named Pipes should be TCP/IP

Status
Not open for further replies.

DougP

MIS
Dec 13, 1999
5,985
US
I am getting and error on my ASP page written in VB Script
here is the code
<%
Set Conn = server.CreateObject(&quot;ADODB.Connection&quot;)
Conn.Open &quot;driver=SQL Server;server=mysite.webplace.com;uid=xxxx;pwd=yyyy;database=mydb;&quot; <<<<<<< This is line 14 >>>>>>>
Set RS1 = Conn.Execute(&quot;SELECT * From Customers Where [WEBLogin] = '&quot; & login & &quot;' AND [WEBPassword] ='&quot; & pass & &quot;'&quot;)
%>

here is the error
---------------------
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][Named Pipes]SQL Server does not exist or access denied.
/asp/tableof.asp, line 14
------------------
The Host company says the error refers to me trying to connect using Named Pipes, I should be connecting using TCP/IP. Can some one help me with the syntax???

This does not work either
<%
Set Conn = server.CreateObject(&quot;ADODB.Connection&quot;)

Conn.Open &quot;Provider=SQLOLEDB;Data Source=000.00.000.000;Initial Catalog=mydb;User ID=xxxx; Password=yyyy&quot;

Set RS1 = Conn.Execute(&quot;SELECT * From Customers Where [WEBLogin] = '&quot; & login & &quot;' AND [WEBPassword] ='&quot; & pass & &quot;'&quot;)
%>
the error is different but still no access
--------------
Microsoft OLE DB Provider for SQL Server error '80004005'
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.
/asp/tableof.asp, line 14
-------------------

TIA DougP, MCP
 
DougP,

Does the database reside on your web server or on another server? If on another server, do you have the IP address of that server and/or if you have DNS, is that name translating properly?


fengshui_1998
 
It resides on another server, our WEB host's.

This is a page from our WEB site. So the code has to work on any machine any where. DougP, MCP
 
Why do you use DataSource?


sConnectionString = &quot;Provider=SQLOLEDB.1;server=SERVERNAME;database=DATABASENAME;uid=XXX;pwd=XXXXXX&quot;
 
If you un-check the Emotions/Smileys in the Step2 Options row below the smiley won't show up in the middle.

Can you do that and repaste the string DougP, MCP
 
sConnectionString = &quot;Provider=SQEDB.1;server=SERVERNAME;database=DATABASENAME;uid=XXX;pwd=XXXXXX&quot;
 
sConnectionString = &quot;Provider=SQLEDB.1;server=SERVERNAME;database=DATABASENAME;uid=XXX;pwd=XXXXXX&quot;
 
here is what I had to use

Conn.Open &quot;Provider=SQLOLEDB.1;Password=PASSWORD;Persist Security Info=True;User ID=USERID;Initial Catalog=universal1;Data Source=SERVERNAMEt;network=dbmssocn&quot;
the &quot;network=dbmssocn&quot; on the very end forces it to use TCP/IP

Thanks to all

DougP, MCP
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top