Friday, March 9, 2012

error connecting to sql db

I have an asp.net project on my laptop 'supposed to be' connecting to a SQL DB on the same machine. But I keep getting this error:

System.Data.SqlClient.SqlException: Cannot open database requested in login 'ASPState'. Login fails. Login failed for user 'xyz'.

It's driving me nuts. Any help would be appreciated.

txs
sonnersYou have to go to Sql Server Manager, go to the database, click Add New User and add the user that needs permission, then give that user owner permission|||I did all this. My SQL knowledge isn't so bad. I've been using the main SQL login account as it's my local machine. This account works for other ASP sites but not for .Net ASP site.|||What does your connection string look like? You may need to add <identity impersonate="true"/> to your web.config file.

Terri

No comments:

Post a Comment