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

sqlConnection not working in VS.net IDE

Inside VS.net, I'm using the Data Form wizard to creat a DataSet and a
Data Connection to my sql database on my network. VS.net creates this
code after I point it to the correct database:

Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security
Info=False;User ID=xx;Initial Catalog=Northwind;Data
Source=TAURUSSQL;Use Procedure for Prepare=1;Auto Translate=True;Packet
Size=4096;Workstation ID=PROG1;Use Encryption for Data=False;Tag with
column collation when possible=False

...but after i finish the data form and try to bring up records when i
run the project, i get a prompt/error: "Login failed for user '(null)'.
Reason: Not associated with a trusted SQL Server connection." ..when the
same userid has no problem on my other sql connection scripts. I even
tried inserting the password in the above string and i still get the
same exact error.

muench

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 21 '05 #1
6 1476
Take the user id and password out of the connection string if you're
using integrated security.

--Mary

On Tue, 13 Apr 2004 13:48:52 -0700, J. Muenchbourg <an*******@dex.com>
wrote:
Inside VS.net, I'm using the Data Form wizard to creat a DataSet and a
Data Connection to my sql database on my network. VS.net creates this
code after I point it to the correct database:

Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security
Info=False;User ID=xx;Initial Catalog=Northwind;Data
Source=TAURUSSQL;Use Procedure for Prepare=1;Auto Translate=True;Packet
Size=4096;Workstation ID=PROG1;Use Encryption for Data=False;Tag with
column collation when possible=False

..but after i finish the data form and try to bring up records when i
run the project, i get a prompt/error: "Login failed for user '(null)'.
Reason: Not associated with a trusted SQL Server connection." ..when the
same userid has no problem on my other sql connection scripts. I even
tried inserting the password in the above string and i still get the
same exact error.

muench

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Jul 21 '05 #2
Take the user id and password out of the connection string if you're
using integrated security.

--Mary

On Tue, 13 Apr 2004 13:48:52 -0700, J. Muenchbourg <an*******@dex.com>
wrote:
Inside VS.net, I'm using the Data Form wizard to creat a DataSet and a
Data Connection to my sql database on my network. VS.net creates this
code after I point it to the correct database:

Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security
Info=False;User ID=xx;Initial Catalog=Northwind;Data
Source=TAURUSSQL;Use Procedure for Prepare=1;Auto Translate=True;Packet
Size=4096;Workstation ID=PROG1;Use Encryption for Data=False;Tag with
column collation when possible=False

..but after i finish the data form and try to bring up records when i
run the project, i get a prompt/error: "Login failed for user '(null)'.
Reason: Not associated with a trusted SQL Server connection." ..when the
same userid has no problem on my other sql connection scripts. I even
tried inserting the password in the above string and i still get the
same exact error.

muench

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Jul 21 '05 #3


Thanks Mary for reply. Yes, I started a new connection and made it
Windows Integrated Security, without a User or password designation, and
it still gave me the same error

???????????

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 21 '05 #4


Thanks Mary for reply. Yes, I started a new connection and made it
Windows Integrated Security, without a User or password designation, and
it still gave me the same error

???????????

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 21 '05 #5
Have you set up a connection in the Server Explorer using these
credentials? That may be a good way to troubleshoot this thing. Null
user means the server is not seeing a valid user.

--Mary

On Wed, 14 Apr 2004 14:52:23 -0700, J. Muenchbourg <an*******@dex.com>
wrote:


Thanks Mary for reply. Yes, I started a new connection and made it
Windows Integrated Security, without a User or password designation, and
it still gave me the same error

???????????

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Jul 21 '05 #6
Have you set up a connection in the Server Explorer using these
credentials? That may be a good way to troubleshoot this thing. Null
user means the server is not seeing a valid user.

--Mary

On Wed, 14 Apr 2004 14:52:23 -0700, J. Muenchbourg <an*******@dex.com>
wrote:


Thanks Mary for reply. Yes, I started a new connection and made it
Windows Integrated Security, without a User or password designation, and
it still gave me the same error

???????????

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Jul 21 '05 #7

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

Similar topics

1
by: Donnie Darko | last post by:
I'm trying to understand SqlConnection(), SqlCommand() For example. I use SqlConnection() as a parameter when I create a new SqlCommand. Then I open SqlConnection(), then I execute the...
17
by: LP | last post by:
Hello, Here's the scenario: Object A opens a Sql Db connection to execute number of SqlCommands. Then it needs to pass this connection to a constructor of object B which in turn executes more...
2
by: Sgt. Sausage | last post by:
New to multi-threading (less than 24 hours at it <grin>) Anyway, it's all making sense, and working fairly well thus far, but I'm having a minor issue I'm not sure how to get around. I've got...
16
by: ed_p | last post by:
Hello, I have implemented the singleton pattern for a class to hold a SqlConnection object that will be used thruout the application to create commands. My application is a simple Windows Form...
4
by: Nevyn Twyll | last post by:
I've been working on an asp.net application and everything's been great. But suddenly, whether I'm tyring to use a database on my own machine, or on my server, I'm getting a timeout when trying to...
2
by: neodev | last post by:
Hi I have 2 mode for open db 'Path DB Private Const pathDB As String = "C:\...\diabolik.mdb" 'for the ole db Private conn As New OleDbConnection 'for th sqlconnection Private connRS As...
8
by: John J. Hughes II | last post by:
Is there a way of resetting the SqlConnection with closing/opening it again. I am not seeing anything called reset. Regards, John
4
by: Victor | last post by:
Hi Guys I have a problem here. I want to improve the performance for a website. When I looked into the system, I have found that the system made the "SqlConnection Object" static. That mean only...
4
by: =?Utf-8?B?dGhlIGZyaWVuZGx5IGRpc3BsYXkgbmFtZQ==?= | last post by:
Hello, I am planning to use three databases on the local SQL Server. DB1 will be for App1, DB2 for App2, and DB3 will hold tables, that both, App1 and App2 need to access. With applications...
2
by: cj | last post by:
MySQLConnection.connectiontimeout() returns 15. I want to drop that to 3, but it is read only. I see you can include the timeout "Connection Timeout=30" as part of the connection string but I...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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...

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.