473,322 Members | 1,401 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,322 software developers and data experts.

No Trusted SQL Server Connection

I'm a programmer but not a database administrator and really don't want to
be either.

After a fair amount of reading and many problems related to SQL and related
stuff, I finally figured out how to create a database in Visual Studio and
enter some data into it. Now, I'm trying to make a Web site application
populate an HTML table with that data. (Running locally.)

Now, when I run the code, I get the error "Login failed for user ''. The
user is not associated with a trusted SQL Server connection."

It appears to be related to my SQL connection string, which is currently
"Data Source=localhost\\SQLEXPRESS;Initial Catalog=DataTest;"

It seems like that should work. Can anyone help me figure out the problem?

Thanks.

--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com
Aug 27 '06 #1
2 991
KJ
Try adding Trusted_Connection=Yes to the connection string. What
happens?

Jonathan Wood wrote:
I'm a programmer but not a database administrator and really don't want to
be either.

After a fair amount of reading and many problems related to SQL and related
stuff, I finally figured out how to create a database in Visual Studio and
enter some data into it. Now, I'm trying to make a Web site application
populate an HTML table with that data. (Running locally.)

Now, when I run the code, I get the error "Login failed for user ''. The
user is not associated with a trusted SQL Server connection."

It appears to be related to my SQL connection string, which is currently
"Data Source=localhost\\SQLEXPRESS;Initial Catalog=DataTest;"

It seems like that should work. Can anyone help me figure out the problem?

Thanks.

--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com
Aug 28 '06 #2
Dear Jonathan,

You may try to use in web.config identity=impersonate

"Jonathan Wood" wrote:
I'm a programmer but not a database administrator and really don't want to
be either.

After a fair amount of reading and many problems related to SQL and related
stuff, I finally figured out how to create a database in Visual Studio and
enter some data into it. Now, I'm trying to make a Web site application
populate an HTML table with that data. (Running locally.)

Now, when I run the code, I get the error "Login failed for user ''. The
user is not associated with a trusted SQL Server connection."

It appears to be related to my SQL connection string, which is currently
"Data Source=localhost\\SQLEXPRESS;Initial Catalog=DataTest;"

It seems like that should work. Can anyone help me figure out the problem?

Thanks.

--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com
Aug 28 '06 #3

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

Similar topics

2
by: bigDWK | last post by:
Hi- Is it possible to do a trusted connection for a web server not on the same physical machine. By this I mean can I make a remote connection from a web server to a sql server using a trusted...
2
by: DMS | last post by:
am new to ASP.NET and IIS web applications, but not to SQL databases. I can successfully build Windows apps using Visual Studio that use ADO. However, for Web Forms, I created data connection and...
2
by: Blake Versiga | last post by:
I am pulling my hair out..... I am trying to put a bound data grid on a webform... I have 4 data connections in my server explorer, all of which connect successfully. But when I run the web...
4
by: Brian Henry | last post by:
I an trying to connect to a sql server in asp.net with the sql connection object, and every time i try to open the connection i get this Server Error in '/' Application. Login failed for user...
7
by: Ray Valenti | last post by:
I am able to preview this data in the development environment, but when I run the application the error below shows up. How do I set up a Trusted Connection? -Ray Server Error in...
2
by: Paul M | last post by:
Hi, I've just implemented my first application onto a test web server. When the code comes to creating a connection object it throws an error saying the "Login failed for user '(null)'. Reason...
5
by: Adam Getchell | last post by:
Hello all, I've read over: http://idunno.org/dotNet/trustedConnections.aspx I would like to use a trusted connection vice using encrypted database strings:...
5
by: Mythran | last post by:
I have a test server and a development machine. I have SQL Server installed on both, the installations are pretty much identical. Both servers are in the same domain. When I run my application...
3
by: Mad Scientist Jr | last post by:
I am getting the following error when trying to access a database with a trusted connection: "Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection." My...
4
by: eruth | last post by:
There are loads of post on this, but nothing that seems to cover my exact problem ;) I have an ASP.Net 1.1 web application running on my local machine. I want to connect to an SQL 2005 server...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.