Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to specify Trusted Connection?
Message
General information
Forum:
ASP.NET
Category:
Databases
Environment versions
Environment:
C# 2.0
Miscellaneous
Thread ID:
01438452
Message ID:
01438468
Views:
34
>>Hi,
>>
>>When calling a stored procedure from a simple/test .NET project and using "sa" for user ID I get error
>>
>>Login failed for user 'sa'
>>The user is not associated with a trusted SQL connection
>>
>>
>>In comparison, when calling SQL from my VFP application I have connection string with [Trusted_Connection=Yes]. Is this what is missing in my .NET connection string? If so, who do I specify it in my .NET connection string?
>>
>>TIA
>
>Trusted connection means you are using your windows username/password that you logged in to windows with. You do not specify a username or password in the connectionstring - just that trusted_connection = True.
>
>If you want to specufy a SQL username/password in your connectionstring, then do not include the Trusted_Connection parameter or set it to False.

Again, thank you very much. All works now. I simply removed references to user ID and password and instead have Trusted_Connection=True and it works.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform