SQL Server in WebApp
Hellow everybody
I have connection problem in Web Application with SQL Server.
I created sqlConnection, sqlDataAdapter, dataset with Designer.
I tested connection and data fill with Designer and it's okey.
But when I run the application exception is throwed on code line :
adapter.Fill(dataset)
Exception message is 'SqlException: Login failed for user 'STATION\ASPNET''
What is the problem and how to solve it ? Are there forums on SQL Server
in internet ?
Thank you
[556 byte] By [
yosef] at [2007-11-19 2:30:01]

# 1 Re: SQL Server in WebApp
As you know, both SQL Server and ASP.NET are both very security conscious.
As such, you need to define the ASP.NET username as a valid login account inside SQL Server (as the release notes probably indicated).
To do this, you can simply create a login with access to the databases you're working on inside SQL Server assigned to the domain\user for your ASP.NET account, which from your comments is STATION\ASPNET (station being your domain name I assume).
If you check the authentication settings of your ASP.NET application (inside web.config), you can also use another login if you like. This would be an impersonation type of login. Again this login would need access to the database too. It is this file that controls your user login account being used and also the type of authentication being used while the application runs.
Hope this helps,
- Nigel
NigelQ at 2007-11-9 13:39:06 >
