Groups | Blog | Home
all groups > inetserver asp db > february 2005 >

inetserver asp db : connection string--setup problems


middletree
2/21/2005 11:16:15 PM
I have posted this to the asp.general group, but the answers given there
have not addressed the problem, so I'll try here.

Set up a W2003 machine at home. IIS is working. I placed an Intranet-based
app that I wrote at work, onto this home machine. I rebuilt the SQL Server
2000 db exactly the same, and it appers to be done correctly.

However, I can't make my ASP app work on this machine. Speifically, the
error I get is

Login failed for user 'asp'
line 14.

Now, here's the code for the connection string:

<%
Dim strDBConnection
strDBConnection = _
"Provider=SQLOLEDB;" & _
"Persist Security Info=False;" & _
"Data Source=w2003\ticketlog;" & _
"User ID=asp;" & _
"Password=asp;" & _
"Database=argonet;"

Dim objConnection
Set objConnection = Server.CreateObject("ADODB.Connection")
objConnection.Open strDBConnection

%>
========================

Please keep in mind the following:

1. I went to aspfaq.com; didn't see anything that addressed this.
2. I am 100% sure that the name and password are correct.

middletree
2/22/2005 10:39:19 AM

[quoted text, click to view]

I backed up the SQL server DB, then restored it on the new machine. I copied
the ASP files over to the same location/path on the new server.
(Garden-variety inetpub/wwwroot directory. I like to keep things simple).
The only thing I did by hand on the new machine was add the user and grant
permissions.

Because I have it working on my work laptop, I am able to have both machines
side by side and make comparisons.

[quoted text, click to view]

OK, I'll try that.

Agoston Bejo
2/22/2005 3:50:54 PM

[quoted text, click to view]

How did you rebuild it "exactly the same"? Created everything by hand?
I remember having problems with database user accounts when transferring
database by backing them up and then restoring on the other server. (Namely
the users just disappeared but I couldn't create them again.)
As a temporary solution, you may create another user in your db and change
your connection string accordingly.


[quoted text, click to view]

AddThis Social Bookmark Button