Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

trying to get aspx application to connect to sql 2008

Posted on 2010-01-07
3
Medium Priority
?
221 Views
Last Modified: 2012-05-08
Hey,
I am migrating an aspx application across to SBS2008 with a seperate SQL2008 server.

I have the site setup in IIS. I have the SQL server on the second server working however when I run the application I get

System.Data.SqlClient.SqlException: Login failed for user 'admin'.

The connection string from the web.config file looks like this

<add name="Application_Database" connectionString="Data Source=sql.domain.local;User ID=admin;Password=password;INITIAL CATALOG=abc123;Connect Timeout=15" />

What am I not doing right?

Cheers
Mitch
0
Comment
Question by:SM17CH
3 Comments
 
LVL 31

Accepted Solution

by:
James Murrell earned 1000 total points
ID: 26197900
0
 
LVL 7

Assisted Solution

by:waltersnowslinarnold
waltersnowslinarnold earned 1000 total points
ID: 26198133
Do few changes as specified below..,

<add name="Application_Database" connectionString="Data Source=serverIP;User ID=serverUsername;Pwd=serverPassword;INITIAL CATALOG=DatabaseName; Connect Timeout=15" />
0
 
LVL 2

Author Comment

by:SM17CH
ID: 26198156
after stuffing around for hours I fixed it :)
SQL server was running in Windows Authentication mode only. I had to go into the SQL server properties (in the SQL manager) and change authentication to Windows and SQL (ie: mixed mode).
Thanks for the input guys.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…

572 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question