473,396 Members | 1,707 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

ASP / SQLServer connection

Hi, I'm having trouble connecting to SQLServer in my ASP program.

here's the code

<%
dim objConnection, ObjRecorSet, strConnection, strOut, objCmd, objParameters
Set objConnection = Server.CreateObject ("ADODB.Connection")
strConnection = "DSN=SQL_Tracker;Database=Tracker;UID=sa;PWD=; "
objConnection.Open strConnection
....
%>

I'm getting this error on the line that opens the connection.

Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E4D)
[Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user
'HOME\IUSR_HOME'.
/Tracker/list_team.asp, line 11
Notes:

I've set up the DSN called 'SQL_Tracker' in my ODBC settings.
When I use the Test Connection button it's successful.

The SQL Server is running on my own computer, and so I have
full DBA rights on it

any ideas what's wrong?
Jul 19 '05 #1
2 3614
Your connection string uses SQL authentication but the error message looks
like Windows authentication was attempted. Did you specify SQL
authentication or Windows authentication in your ODBC setup? Is your SQL
Server configured to allow both SQL and Windows authentication?

Also, note that you should never use 'sa' for application database
connections and you may get uninvited guests with a blank 'sa' password.

--
Hope this helps.

Dan Guzman
SQL Server MVP

"Peter Morris" <nospam.ple@se> wrote in message
news:Rm****************@text.news.blueyonder.co.uk ...
Hi, I'm having trouble connecting to SQLServer in my ASP program.

here's the code

<%
dim objConnection, ObjRecorSet, strConnection, strOut, objCmd,
objParameters
Set objConnection = Server.CreateObject ("ADODB.Connection")
strConnection = "DSN=SQL_Tracker;Database=Tracker;UID=sa;PWD=; "
objConnection.Open strConnection
...
%>

I'm getting this error on the line that opens the connection.

Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E4D)
[Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user
'HOME\IUSR_HOME'.
/Tracker/list_team.asp, line 11
Notes:

I've set up the DSN called 'SQL_Tracker' in my ODBC settings.
When I use the Test Connection button it's successful.

The SQL Server is running on my own computer, and so I have
full DBA rights on it

any ideas what's wrong?

Jul 19 '05 #2
Stop using ODBC/DSN. This may not resolve the issue, but at least your
application will be faster & the database connection will be supported
in the future.

Please read the following pages.

http://www.aspfaq.com/show.asp?id=2126

http://msdn.microsoft.com/library/de...components.asp

Peter Morris wrote:
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E4D)
[Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user
'HOME\IUSR_HOME'.
/Tracker/list_team.asp, line 11

--
Please do not contact me directly or ask me to contact you directly for
assistance.

If your question is worth asking, it's worth posting.

If it’s not worth posting you should have done a search on
http://www.google.com/ http://www.google.com/grphp?hl=en&tab=wg&q= or
http://news.google.com/froogle?hl=en&tab=nf&ned=us&q= before wasting our
time.
Jul 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Gary Whitten | last post by:
We have a JDBC project that works with SQLServer, along with other DBs. During development, we noticed that resource useage on SQLServer seemed to grow steadily - Processes, Process Locks and/or...
1
by: mdurliSPAMFILTER | last post by:
Hello, I developed a win32 .exe CGI that connects to a clustered SQLServer to report some data. The software is written with Borland C++Builder. This is the oledb string:...
14
by: Roy Gourgi | last post by:
Hi, I need to store and retrieve information from a database. It looks as though there is a lot more support for SQLServer than there is for Access, correct me if I am wrong. What do I have...
2
by: saroxonline76 | last post by:
Dear all, I installed Visual Basic 2005 Express and SqlServer Express. I tried some features of both of them but I'm not able to connect a databse through a network. To explain, I have two...
3
by: Dan Sikorsky | last post by:
Can I use SQLServer 2000 with ASP.NET 2.0 instead of SQLServer 2005, and use the .Net 2.0 Membership functionality? I've setup my Login page, controls, etc., and now it's time to use the Web...
2
by: dgk | last post by:
I'm using the standard provider for membership which is SQLServer Express. After deploying the app to our server, login fails because of an SQL problem. I'm guessing that the problem is that the...
5
by: alingsjtu | last post by:
Hello, every body. When execute dynamic generated multiple OPENQUERY statements (which linkes to DB2) in SQLServer, I always got SQL1040N The maximum number of applications is already connected...
7
by: kuldeep singh sethi | last post by:
Hi friends, i am suffering with one problem. i am unable to make connectivity between .net 2003 and sqlserver. I want to make connection String with sqlserver. but not possible. i am a new learner...
2
by: =?Utf-8?B?SmVmZnJleQ==?= | last post by:
How to configure the IIS, ASPNET userID, Windows or SQL Authentiation, std or integrated security for SQLserver database? The VS.net 2002 web server and SQL Server client are at the same PC, ...
21
by: adjo | last post by:
I am working on an app with an Access2002 frontend and Sql2005 backend. I have to use integrated security. I want to prevent my users from altering data in another way than via the frontend. It...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.