Solved

Authentication error in ASP page

Posted on 2007-04-02
5
340 Views
Last Modified: 2012-06-27
Hi Experts,

I have changed my one of my server from windows 2000 to 2003 its running SQL 2000, All the link servers and the security accounts are some of my ASP pages are coming with the following error,

(Login failed for user 'sa'. Reason: Not associated with a trusted SQL Server connection.)

How can I check that where I'm going wrong, I can send you the code I'm using in the page and the other settings of my server, any help to trace out this problem will be much appreciated.

Many Thanks,
0
Comment
Question by:Impex
  • 2
  • 2
5 Comments
 
LVL 2

Expert Comment

by:vjc2003
ID: 18836086
If u havent done this already,
check connection string in the configs.
Have u enabled Windows and Sql server authentication for  the DB?

0
 

Author Comment

by:Impex
ID: 18836137
The SQL is on windows and SQL authentication since I have installed the server, I was looking on Google and Microsoft acticles about this problem. All of them say the same thing like enabled Windows and Sql server authentication in security tab of the server which is already done.
0
 
LVL 8

Expert Comment

by:Julianva
ID: 18836340
What account are you using to connect  from the asp page to sql server is it SQL auth or windows auth. the connectio string should be in the asp page. you need to check in sql enterprise manager that the windows account is created on SQL server

security - logins -

the error you are getting is a windows auth error , happen when you dont have a windows account login in SQL server.




0
 

Author Comment

by:Impex
ID: 18838093
This is the connection string I'm using in ASP code,
string str="User ID=sa;Initial Catalog=SDXArchiver;Data Source=server1";

I have added an account in SQL which is DOMAIN\ADMIN and given in full control on all the data bases.
How can I configure my ASP file to use the domain admin account in order to get the information from server1.

Cheers!
0
 
LVL 2

Accepted Solution

by:
vjc2003 earned 250 total points
ID: 18841298
For using windows authentication conn. string has to be like
connectionString="Initial Catalog=MyDb;Data Source=MyServer;Integrated Security=SSPI;"

Also you will have to configure IIS to run the application with DOMAIN\ADMIN account
It is a better idea to use a specific account for this and not an ADMIN account.

btw are your application and DB on different machines?
0

Featured Post

Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

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.
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

867 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now