|
Home > Archive > IIS ASP > December 2004 > Problem on Asp ODBC Connection to SQL Server
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Problem on Asp ODBC Connection to SQL Server
|
|
|
| Dear All,
I have problem on data connection to a SQL Server by Asp Statement.
It's Very strange that my asp statement can connect to one remote SQL server
but can't connect to other remote SQL server.
The statement written like this :
Set DBLBX=Server.CreateObject("ADODB.Connection")
DBLBX.Open "DSN=DBWEB;UID=opn;PWD=opn;"
It show the follows:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no default
driver specified
Is that the problem of my Sql server ?
Thanks all.
| |
| Bob Barrows [MVP] 2004-12-27, 7:46 am |
| EDDIE wrote:
> Dear All,
>
> I have problem on data connection to a SQL Server by Asp Statement.
> It's Very strange that my asp statement can connect to one remote SQL
> server but can't connect to other remote SQL server.
> The statement written like this :
>
> Set DBLBX=Server.CreateObject("ADODB.Connection")
> DBLBX.Open "DSN=DBWEB;UID=opn;PWD=opn;"
>
> It show the follows:
>
> Microsoft OLE DB Provider for ODBC Drivers error '80004005'
> [Microsoft][ODBC Driver Manager] Data source name not found and no
> default driver specified
>
> Is that the problem of my Sql server ?
>
> Thanks all.
Part of the problem is that you are using the obsolete ODBC provider when
there is a perfectly good native sql server provider available (SQLOLEDB).
See http://www.aspfaq.com/show.asp?id=2126
Also relevant is this article, which is a compendium of all the causes of
database-related 80004005 errors:
http://www.aspfaq.com/show.asp?id=2009
Bob Barrows
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
| |
|
| Many thanks.
I have solved it by using OLEDB.
Thx ^^
"Bob Barrows [MVP]" <reb01501@NOyahoo.SPAMcom> ¦b¶l¥ó
news:%23NmXdNB7EHA.3120@TK2MSFTNGP12.phx.gbl ¤¤¼¶¼g...
> EDDIE wrote:
>
> Part of the problem is that you are using the obsolete ODBC provider when
> there is a perfectly good native sql server provider available (SQLOLEDB).
> See http://www.aspfaq.com/show.asp?id=2126
>
> Also relevant is this article, which is a compendium of all the causes of
> database-related 80004005 errors:
> http://www.aspfaq.com/show.asp?id=2009
>
> Bob Barrows
> --
> Microsoft MVP - ASP/ASP.NET
> Please reply to the newsgroup. This email account is my spam trap so I
> don't check it very often. If you must reply off-line, then remove the
> "NO SPAM"
>
>
|
|
|
|
|