Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Invalid connection string attribute Error

4 views
Skip to first unread message

R. Deavers

unread,
Dec 22, 2009, 9:53:01 AM12/22/09
to
We recently upgraded our SQL 2000 database to SQL2005. We have several COM
objects, written in Visual Basic 6.0, using a basic connection string to
connect to the database. We installed the SQL native client on the Windows
2003 Server running the objects. All objects use the same code to connect to
the database and have been working properly for years. However, since the
upgrade, one object gets an error back from the connection object stating
“Invalid connection string attribute” with a SQL state 01S00. Also, the
recordset is being returned. The only difference between this object and the
others (btw they all share the same connection string below) is that the one
returning the error is ran out of ASP 3.0 while the others are in COM+.
Provider=SQLNCLI;Data Source=cnDB;Database=DatabaseName;uid=OurUser;pwd=Empty;

Erland Sommarskog

unread,
Dec 22, 2009, 6:04:14 PM12/22/09
to
Rather than "Data Source", try "Server".


--
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

R. Deavers

unread,
Dec 23, 2009, 8:04:01 AM12/23/09
to
I made the suggested change and still received the error.

"Erland Sommarskog" wrote:

> .
>

Erland Sommarskog

unread,
Dec 23, 2009, 4:43:18 PM12/23/09
to
R. Deavers (RDea...@discussions.microsoft.com) writes:
> I made the suggested change and still received the error.

One idea is to take out one attribute at a time, until you get a different
error message.

And, try this: change SQLNCLI to BOGUS. If it now does not scream about
a non-existing provider, you are not using the connection string you
think you are.

R. Deavers

unread,
Dec 28, 2009, 9:51:01 AM12/28/09
to
Thanks again for your suggestions and help in trying to help me identify the
problem.

Just to clarify I have 6 objects (1 used in ASP and 5 in COM+) that were
compiled using the same Database code “module”. They all use the same
connection string which is stored in a text file. I verified this by
changing the provider to “BOGUS” as recommended. I then removed one
parameter at a time and based on which parameter got the appropriate error
message. I should note that the password is blank but yet we include the
“pwd=;” parameter. I don’t think this is the issue since the other objects
are working fine. I should also mention that the error occurs
intermittently. I would say at a rate of 1 error to 6 requests. Any more
suggestions would be greatly appreciated.

"Erland Sommarskog" wrote:

> .
>

Erland Sommarskog

unread,
Dec 28, 2009, 5:42:37 PM12/28/09
to
R. Deavers (RDea...@discussions.microsoft.com) writes:
> Thanks again for your suggestions and help in trying to help me identify
> the problem.
>
> Just to clarify I have 6 objects (1 used in ASP and 5 in COM+) that were
> compiled using the same Database code "module". They all use the same
> connection string which is stored in a text file. I verified this by
> changing the provider to �BOGUS� as recommended. I then removed one
> parameter at a time and based on which parameter got the appropriate
> error message. I should note that the password is blank but yet we
> include the �pwd=;� parameter. I don�t think this is the issue since

> the other objects are working fine. I should also mention that the
> error occurs intermittently. I would say at a rate of 1 error to 6
> requests. Any more suggestions would be greatly appreciated.

Intermittently? This is not fun anymore! That is, I don't have a clue.
If you get an error like "Invalid connection string attribute" inter-
mittently, this smells like memory thrashing to me. But it would take
quite some skill to thrash memory from ASP, wouldn't it? But there
could be bugs in ASP. And this "module" that you mention is in C++,
that could be the culprit.

Hm, can you log from ASP what connection string you actually get?

0 new messages