It would help if you showed your connection code (minus password of course)
Main Topics
Browse All TopicsHi,
When ever im trying to run my application im getting this error
SQL Server does not exist or access denied.
i use xml configuration file in my web.config file to connect to my DB.Even though the db name is right and it exists i keep getting this error...can anyone help me on this,
Thanks
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Yeah, if you're using a trusted connection without an impersonate it's probably trying to connect as aspnet. Either specify the User ID & Password in your connection string, give the proper rights to aspnet or add an impersonate to your web.config. Oh I just remembered, there's always UseDefaultCredentials.
Any combination of those should work.
Trying to give ASPNET (for Win2K -- it will be NETWORK SERVICE for Win2003) access to the SQL Server will be a headache because the ASPNET or NETWORK SERVICE accounts are local to the IIS server and the SQL Server (I am assuming they are on different boxes here) will not know anything about these accounts. The comment above about using SQL Server Auth and specifying the username and password in the connection string is the easiest path to solving this.
Alternately, if you are allowing anonymous requests to the web site, create a domain/AD account strictly for the web site's database access. Then change IIS to use this account to authenticate anonymous requests. Then add this account to the SWL Server Logins section (under the Security node). Then add the account to the database's Users.
John
Any reason all solutions that suggested credentials were marked for a split, but mine- which is also a plausible cause of the wrong port being used - was not included in the split?
I think all are equally viable possibilities and all should be included in a split or a delete no refund should be done.
I am concerned with what is being documented as possible solutions not with points. Go ahead and assign 0 points, I would have the same point to make - even if there were no points on the site at all.
But others coming later to look should see what are actual possible solutions if this is being marked as solved - or it should be deleted if it is unclear that any were solutions.
Business Accounts
Answer for Membership
by: mrichmonPosted on 2006-10-24 at 09:36:33ID: 17797184
Are you connecting onthe correct port?