Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to connet to SQL Server newbie?
Message
General information
Forum:
ASP.NET
Category:
ADO.NET
Miscellaneous
Thread ID:
00940862
Message ID:
00941041
Views:
8
>I wanted to add to my privious message that I have no problem connecting to the database from VFP using the following syntax:
>
>
>hCon = SQLSTRINGCONNECT([DRIVER=SQL Server;SERVER=(local);DATABASE=MyDatabase;Trusted_Connection=Yes])
>
>

The reason you get the "login failed for NOTEBOOK\ASPNET" when you run it in .NET and not when you run it in VFP is because when you run a Web Application the application itself is running as this "ASPNET" user (not as NOTEBOOK\DLITVAK)

To get around this, try to switch SQL Server to support mixed mode authentication (as Steven mentioned) and then use a connection string that has the username/password on it (rather than using integrated security.)
Hector Correa
Previous
Reply
Map
View

Click here to load this message in the networking platform