SQL data access via Service Account from ASP.NET


I am writing a WCF service to access a stored procedure in SQL 2000.
I am unable to make it possible since VS2010 does not support SQL 2000.
I tried SQLMetal Builder to build the LINQ2SQL context, but no use.
So finally, i am writing a web service in VS2008.
I am able to access the Stored Procedure via SQL Authentication.
But i have a service account which i should be using to run the web service under to access the stored procedure.

How can i do that?
Any advice regarding VS2010 will be appreciated.

Thank You
Who is Participating?
PryratesConnect With a Mentor Commented:
You have to grand access to the SQL server for your service account.
If the SQL Server and the WCF-Service are running on the same machine you can use a local account to do that.
SQL Server 2000 was a long time ago, but you somehow you will be able to manage to add some user account to the server.

If they are running on different machines you will need AD some account.
If the service is run under the service account you will have to do nothing at all regarding the connection to the SQL server.
Otherwise you will need to do some impersonate stuff around the call of the Stored procedure.

You can do that the "hard" way like that:
or like that

Here is a good article covering that toppic:

Hope that helps

kreddy01Author Commented:
help please
Amandeep Singh BhullarCommented:
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.