FuzzBox
Oct 22nd, 2002, 06:43 AM
Could someone explain why I can’t get access to my SQL database. After all I did create it myself :) It’s a simple database with two linked tables.
The database is on the same PC as SQL server. I have a web page that will display the contents of the database on a data grid at the click of a button (based on a Karl Moore Tutorial). My details:
Operating System Win 2k
IIS version 5
I’m using the NETSDK version of SQL server
My PC name is COCLAP-9
My SQL server is called COCLAP-9\NETSDK
My database is called KeepFit
So, my connection string should look like this:
Dim objConnection As New SqlClient.SqlConnection _
("server=(local)\NETSDK;Trusted_Connection=yes;database=KeepFit")
I have been told that I can’t use Trusted_Connection but since that both the database and the application are on the same PC this is ok. This also worked under the Beta 2 version, but not now.
I had to reinstall my Win 2k since Beta 2 because I could not uninstall Beta 2 no way, no how, without reformatting the hard disk!
Could Win 2k security be linked to the following error message? Anyway, when I hit F5 I get :
Cannot open database requested in login 'KeepFit'. Login fails. Login failed for user 'COCLAP-9\ASPNET'.
The Source Error is
objConnection.Open()
I have read a lot of Microsoft's documentation and have played with machine.config, web config, passwords, etc.. but to no avail. I have tried all my work colleagues but none have used SQL server. I’m really stuck on this one, so any help would be appreciated.
Thanks for you time :)
The database is on the same PC as SQL server. I have a web page that will display the contents of the database on a data grid at the click of a button (based on a Karl Moore Tutorial). My details:
Operating System Win 2k
IIS version 5
I’m using the NETSDK version of SQL server
My PC name is COCLAP-9
My SQL server is called COCLAP-9\NETSDK
My database is called KeepFit
So, my connection string should look like this:
Dim objConnection As New SqlClient.SqlConnection _
("server=(local)\NETSDK;Trusted_Connection=yes;database=KeepFit")
I have been told that I can’t use Trusted_Connection but since that both the database and the application are on the same PC this is ok. This also worked under the Beta 2 version, but not now.
I had to reinstall my Win 2k since Beta 2 because I could not uninstall Beta 2 no way, no how, without reformatting the hard disk!
Could Win 2k security be linked to the following error message? Anyway, when I hit F5 I get :
Cannot open database requested in login 'KeepFit'. Login fails. Login failed for user 'COCLAP-9\ASPNET'.
The Source Error is
objConnection.Open()
I have read a lot of Microsoft's documentation and have played with machine.config, web config, passwords, etc.. but to no avail. I have tried all my work colleagues but none have used SQL server. I’m really stuck on this one, so any help would be appreciated.
Thanks for you time :)