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

change connection string info Expand / Collapse
Author
Message
Posted Tuesday, February 05, 2013 6:46 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Wednesday, February 13, 2013 7:58 AM
Points: 137, Visits: 159
In the connection string information to a sql server 2008 r2 database, I am currently setting the integrated security to true. This way I do not need to pass in user name and password. However there are times when the username and password is required.
When this is the case, can I use a windows identity to pass in the user info? If not, do I need to pass in a sql server username and password?
Can you tell me what the preferred method is?
Post #1416199
Posted Wednesday, February 06, 2013 12:31 AM
Say Hey Kid

Say Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey KidSay Hey Kid

Group: General Forum Members
Last Login: Today @ 1:08 AM
Points: 707, Visits: 1,048
It would depend on the application using the connection string. The SQL engine doesn't care what method of authentication is used, as long as the user is authenticated.
You can pass a SQL login / password, but I think the question you mean to ask is 'why am I being asked for my credentials when I'm using integrated security in my connection string?'. I'd guess the login does not have rights to connect, check the SQL error log for failed logins.
Post #1416280
Posted Wednesday, February 06, 2013 5:11 AM


Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Today @ 3:41 AM
Points: 348, Visits: 1,329
wendy elizabeth (2/5/2013)
However there are times when the username and password is required.

Why?

wendy elizabeth (2/5/2013)
can I use a windows identity to pass in the user info?

Yes, in the connection string set integrated security to true.

wendy elizabeth (2/5/2013)
Can you tell me what the preferred method is?

It depends.


http://thesqlguy.blogspot.com/
Post #1416422
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse