connection problem

D

dap

can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484

System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs e) in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick(EventArgs e)
+108

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292
 
D

dap

conMyData = new SqlConnection( "Server=localhost;
Database=Proton; trusted_connection=true;" )

is this correct? i used this code to connect.
-----Original Message-----
may be incorrect SQL server name,
so you can not log in to it..


dap said:
can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484

System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs e) in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick(EventArgs e)
+108

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292
.
 
W

William F. Robertson, Jr.

You webserver is probably running under the aspnet user account. Have you
set up the aspnet user account to access your localhost SQL instance?

bill

dap said:
conMyData = new SqlConnection( "Server=localhost;
Database=Proton; trusted_connection=true;" )

is this correct? i used this code to connect.
-----Original Message-----
may be incorrect SQL server name,
so you can not log in to it..


dap said:
can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484

System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs e) in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick(EventArgs e)
+108

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292
.
 
D

dap

i don't i have set it. can u tell me how to set it?
-----Original Message-----
You webserver is probably running under the aspnet user account. Have you
set up the aspnet user account to access your localhost SQL instance?

bill

dap said:
conMyData = new SqlConnection( "Server=localhost;
Database=Proton; trusted_connection=true;" )

is this correct? i used this code to connect.
-----Original Message-----
may be incorrect SQL server name,
so you can not log in to it..


:

can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484
System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs
e)
in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick
(EventArgs
e)
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292




.


.
 
W

William F. Robertson, Jr.

There are several different ways to accomplish this. It also depends on
whether you have MSDE, or Sql 2000 installed on your machine.

For my setup. I would open Enterprise manager, select the database you want
access to. Right click the database and select new -> Database user.

Create a new user, using NT authentication, and map that account to you
machinename\aspnet.

Login = <machine name>\aspnet

You will have to set up permissions and stuff through there. You might look
for more information in the
microsoft.public.sqlserver.programming newsgroup.

Or check out Sql books on line.

bill

dap said:
i don't i have set it. can u tell me how to set it?
-----Original Message-----
You webserver is probably running under the aspnet user account. Have you
set up the aspnet user account to access your localhost SQL instance?

bill

dap said:
conMyData = new SqlConnection( "Server=localhost;
Database=Proton; trusted_connection=true;" )

is this correct? i used this code to connect.

-----Original Message-----
may be incorrect SQL server name,
so you can not log in to it..


:

can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during
the
execution of the current web request. Please review
the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484


System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs e)
in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick (EventArgs
e)
+108


System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292




.


.
 
D

dap

ok. i have done it.
But i still have the same problem.
do i have to change in the UID and the PWD? or i can
still use the TRUSTED_CONNECTION?
-----Original Message-----
There are several different ways to accomplish this. It also depends on
whether you have MSDE, or Sql 2000 installed on your machine.

For my setup. I would open Enterprise manager, select the database you want
access to. Right click the database and select new -> Database user.

Create a new user, using NT authentication, and map that account to you
machinename\aspnet.

Login = <machine name>\aspnet

You will have to set up permissions and stuff through there. You might look
for more information in the
microsoft.public.sqlserver.programming newsgroup.

Or check out Sql books on line.

bill

dap said:
i don't i have set it. can u tell me how to set it?
-----Original Message-----
You webserver is probably running under the aspnet
user
account. Have you
set up the aspnet user account to access your
localhost
SQL instance?
bill

conMyData = new SqlConnection( "Server=localhost;
Database=Proton; trusted_connection=true;" )

is this correct? i used this code to connect.

-----Original Message-----
may be incorrect SQL server name,
so you can not log in to it..


:

can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during
the
execution of the current web request. Please review
the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484
System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s,
EventArgs
e)
in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick (EventArgs
e)
+108
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String
eventArgument)
+57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292




.



.


.
 
D

dap

yes it is running.
-----Original Message-----
Is the Sql Server running?

dap said:
can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and
where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]
System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484

System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs e) in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick(EventArgs e)
+108

System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292


.
 
W

William F. Robertson, Jr.

What is the instance name of your server? You might not be able to use
"localhost".

You haven't changed any of your machine.config processModel section have
you?

bill

dap said:
ok. i have done it.
But i still have the same problem.
do i have to change in the UID and the PWD? or i can
still use the TRUSTED_CONNECTION?
-----Original Message-----
There are several different ways to accomplish this. It also depends on
whether you have MSDE, or Sql 2000 installed on your machine.

For my setup. I would open Enterprise manager, select the database you want
access to. Right click the database and select new -> Database user.

Create a new user, using NT authentication, and map that account to you
machinename\aspnet.

Login = <machine name>\aspnet

You will have to set up permissions and stuff through there. You might look
for more information in the
microsoft.public.sqlserver.programming newsgroup.

Or check out Sql books on line.

bill

dap said:
i don't i have set it. can u tell me how to set it?

-----Original Message-----
You webserver is probably running under the aspnet user
account. Have you
set up the aspnet user account to access your localhost
SQL instance?

bill

conMyData = new SqlConnection( "Server=localhost;
Database=Proton; trusted_connection=true;" )

is this correct? i used this code to connect.

-----Original Message-----
may be incorrect SQL server name,
so you can not log in to it..


:

can you tell me what is the problem with this error
statements??

Description: An unhandled exception occurred during
the
execution of the current web request. Please review
the
stack trace for more information about the error and
where it originated in the code.

Exception Details:
System.Data.SqlClient.SqlException:
SQL Server does not exist or access denied.

Source Error:


Line 27: cmdSelect.Parameters.Add( "@username",
strUsername )
Line 28: cmdSelect.Parameters.Add( "@password",
strPassword )
Line 29: conMyData.Open()
Line 30: cmdSelect.ExecuteNonQuery()
Line 31: intResult = cmdSelect.Parameters
( "RETURN_VALUE" ).Value


Source File: c:\inetpub\wwwroot\proton-
commerce\login.aspx Line: 29

Stack Trace:


[SqlException: SQL Server does not exist or access
denied.]

System.Data.SqlClient.ConnectionPool.GetConnection
(Boolean& isInTransaction) +484



System.Data.SqlClient.SqlConnectionPoolManager.GetPooledCo
nnection(SqlConnectionString options, Boolean&
isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.Login_aspx.dbAuthenticate(String strUsername,
String strPassword) in c:\inetpub\wwwroot\proton-
commerce\login.aspx:29
ASP.Login_aspx.Button_Click(Object s, EventArgs
e)
in
c:\inetpub\wwwroot\proton-commerce\login.aspx:10
System.Web.UI.WebControls.Button.OnClick
(EventArgs
e)
+108



System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEv
entHandler.RaisePostBackEvent(String eventArgument)
+57
System.Web.UI.Page.RaisePostBackEvent
(IPostBackEventHandler sourceControl, String
eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent
(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292




.



.


.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,812
Latest member
GracielaWa

Latest Threads

Top