Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Initial Catalog value ignored on SQL connection Expand / Collapse
Author
Message
Posted Thursday, July 28, 2005 8:42 AM
Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Thursday, September 25, 2014 9:35 AM
Points: 373, Visits: 164

We are trying to use NT authentication in our VB6 programs.  We have test and production databases and are trying to test programs using the TEST database, but whenever we set a connection string in VB the SQL statements using that connection string seem to be ignoring the Initial Catalog setting.  It only recognizes the user's default database.  Here's the connection string:

Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=TestJobTrack;Data Source=BSQL;Application Name=ClientAudit

The user testing this program has a default database setting of ProdJobTrack and whenever this user runs this program, it only sees ProdJobTrack data.  This is extremely frustrating as I have looked at several websites for connection string information and I can't see what we are doing wrong - I guess I've just been looking at it too long.  Can anyone help??????  




Post #205339
Posted Thursday, July 28, 2005 11:05 AM
Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Thursday, September 25, 2014 9:35 AM
Points: 373, Visits: 164

This is classic, the programmer told me this was the connection string they were using.  But when I looked at the program I FINALLY found one little problem:

Initial_Catalog

that should have been

Initial Catalog

Looks like it just ignored this parameter which then forced the connection to use the user's default database. 




Post #205412
Posted Tuesday, October 29, 2013 8:58 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, November 5, 2013 8:39 AM
Points: 6, Visits: 33
I'm going to put myself out there as the possible idiot developer who is having the same issue. Here is my connection string, which does not have the same issue as the post before, but is still having the Initial Catalog value ignored.

Data Source=DevSQL01;Inital Catalog=dbStage;Integrated Security=SSPI;Auto Translate=False;Application Name=MRM;

The issue surfaced where an older developed SSIS package updated to VS 2010 seems to have worked until my last update. The server running the SSIS package is SQL Server 2012 connecting to a 2012 database.

Any help would be appreciated.
Post #1509641
Posted Tuesday, October 29, 2013 9:05 PM


SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Today @ 8:06 AM
Points: 895, Visits: 2,523
Bradley McGuffey (10/29/2013)
I'm going to put myself out there as the possible idiot developer who is having the same issue. Here is my connection string, which does not have the same issue as the post before, but is still having the Initial Catalog value ignored.

Data Source=DevSQL01;Inital Catalog=dbStage;Integrated Security=SSPI;Auto Translate=False;Application Name=MRM;

The issue surfaced where an older developed SSIS package updated to VS 2010 seems to have worked until my last update. The server running the SSIS package is SQL Server 2012 connecting to a 2012 database.

Any help would be appreciated.

Best to create another thread instead, you would want to create yours in the SQL Server 2012 General forum. They don't have one for SSIS for some reason.


Shawn Melton
PS C:\>(Find-Me).TwitterURL
@wsmelton
PS C:\>(Find-Me).BlogURL
meltondba.wordpress.com
Post #1509642
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse