Data source name not found and no default driver specified
Data source name not found and no default driver specified
am 06.06.2007 01:33:20 von rabblerowzer
Hi, I have IIS and SQL Server2K on the same machine where I am trying
to get an ASP file to return data. I can not get past this one error
though:
ERROR MESSAGE:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC Driver Manager] Data source name not found and no
default driver specified
/WebFiles/Page1.asp, line 122
I've messed with and tripple checked each of the areas below
-Web Site's Configuration in IIS
-Registry key associated with ODBC Driver
-ODBC driver / DSN
-Changed the connection string in every way.
CONNECTION STRING:
MyConn= "PROVIDER=SQLOLEDB.1;DATA
SOURCE=xxx.xxx.xx.xx;UID=User;PWD=pwd;Network
Library=dbmssocn;Initial
Catalog=DB Name;"
LINE 122:
<%Set MyConn = Server.CreateObject
("ADODB.Connection")
%>
<%Set RS=Server.CreateObject ("ADODB.RecordSet")%>
Any ideas?
Thanks,
Re: Data source name not found and no default driver specified
am 06.06.2007 01:48:12 von reb01501
rabblerowzer@yahoo.com wrote:
> Hi, I have IIS and SQL Server2K on the same machine where I am trying
> to get an ASP file to return data. I can not get past this one error
> though:
>
>
> ERROR MESSAGE:
> Microsoft OLE DB Provider for ODBC Drivers error '80004005'
> [Microsoft][ODBC Driver Manager] Data source name not found and no
> default driver specified
> /WebFiles/Page1.asp, line 122
>
>
> I've messed with and tripple checked each of the areas below
> -Web Site's Configuration in IIS
> -Registry key associated with ODBC Driver
> -ODBC driver / DSN
> -Changed the connection string in every way.
>
>
> CONNECTION STRING:
> MyConn= "PROVIDER=SQLOLEDB.1;DATA
> SOURCE=xxx.xxx.xx.xx;UID=User;PWD=pwd;Network
> Library=dbmssocn;Initial
> Catalog=DB Name;"
>
Well, this is the correct connection string to use
(http://www.aspfaq.com/show.asp?id=2126). What error do you get when you use
it?
Why is it so important to use the IP address with the sql server on the same
machine? Use (local) for the data source instead of the IP.
The connection string attributes should be user id instead of uid, and
password instead of pwd (but this is not your problem)
--
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"
Re: Data source name not found and no default driver specified
am 06.06.2007 02:26:37 von rabblerowzer
On Jun 5, 4:48 pm, "Bob Barrows [MVP]"
wrote:
> rabblerow...@yahoo.com wrote:
> > Hi, I have IIS and SQL Server2K on the same machine where I am trying
> > to get an ASP file to return data. I can not get past this one error
> > though:
>
> > ERROR MESSAGE:
> > Microsoft OLE DB Provider for ODBC Drivers error '80004005'
> > [Microsoft][ODBC Driver Manager] Data source name not found and no
> > default driver specified
> > /WebFiles/Page1.asp, line 122
>
> > I've messed with and tripple checked each of the areas below
> > -Web Site's Configuration in IIS
> > -Registry key associated with ODBC Driver
> > -ODBC driver / DSN
> > -Changed the connection string in every way.
>
> > CONNECTION STRING:
> > MyConn= "PROVIDER=SQLOLEDB.1;DATA
> > SOURCE=xxx.xxx.xx.xx;UID=User;PWD=pwd;Network
> > Library=dbmssocn;Initial
> > Catalog=DB Name;"
>
> Well, this is the correct connection string to use
> (http://www.aspfaq.com/show.asp?id=2126). What error do you get when you use
> it?
>
> Why is it so important to use the IP address with the sql server on the same
> machine? Use (local) for the data source instead of the IP.
> The connection string attributes should be user id instead of uid, and
> password instead of pwd (but this is not your problem)
>
> --
> 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"- Hide quoted text -
>
> - Show quoted text -
Hi Bob,
OK I changed the connection string exactly as you suggested, but I
still get the same error. Any other ideas?
Thanks,
Russ
Re: Data source name not found and no default driver specified
am 06.06.2007 02:47:55 von reb01501
rabblerowzer@yahoo.com wrote:
> On Jun 5, 4:48 pm, "Bob Barrows [MVP]"
> wrote:
>> rabblerow...@yahoo.com wrote:
>>> Hi, I have IIS and SQL Server2K on the same machine where I am
>>> trying
>>> to get an ASP file to return data. I can not get past this one error
>>> though:
>>
>>> ERROR MESSAGE:
>>> Microsoft OLE DB Provider for ODBC Drivers error '80004005'
>>> [Microsoft][ODBC Driver Manager] Data source name not found and no
>>> default driver specified
>>> /WebFiles/Page1.asp, line 122
>>
>>> I've messed with and tripple checked each of the areas below
>>> -Web Site's Configuration in IIS
>>> -Registry key associated with ODBC Driver
>>> -ODBC driver / DSN
>>> -Changed the connection string in every way.
>>
>>> CONNECTION STRING:
>>> MyConn= "PROVIDER=SQLOLEDB.1;DATA
>>> SOURCE=xxx.xxx.xx.xx;UID=User;PWD=pwd;Network
>>> Library=dbmssocn;Initial
>>> Catalog=DB Name;"
>>
>> Well, this is the correct connection string to use
>> (http://www.aspfaq.com/show.asp?id=2126). What error do you get when
>> you use it?
>>
>> Why is it so important to use the IP address with the sql server on
>> the same machine? Use (local) for the data source instead of the IP.
>> The connection string attributes should be user id instead of uid,
>> and password instead of pwd (but this is not your problem)
>>
>
>
> Hi Bob,
>
> OK I changed the connection string exactly as you suggested, but I
> still get the same error. Any other ideas?
>
Instead of using (local), use the actual name of your sql server, which is
usually the same as the name of the machine on which it resides. The only
exception is if you've created multiple instances on the machine.
Use Query Analyzer to run this statement:
Select @@SERVERname
This will show the name of the server to be used as the data source.
If you'e still having problems, show me the new connection string and the
text of your error.
--
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"