System.Data.SqlClient.SqlException: Login failed for user...

Discuss all aspects of programming here.

Moderator: The Mod Squad

System.Data.SqlClient.SqlException: Login failed for user...

Postby Sick_Boy » Wed May 04, 2005 6:11 am

Trying to use a table as a dropdown's datasource but this error drives me crazy. Somebody help please.
Sick_Boy
Initiate
Initiate
 
Posts: 64
Joined: Fri Apr 11, 2003 8:23 am
Location: Turkey

Postby Johnny Mnemonic » Tue Jul 26, 2005 5:58 pm

0100101001001101
Image
Johnny Mnemonic
Black Belt 1st Degree
Black Belt 1st Degree
 
Posts: 1903
Joined: Wed Oct 31, 2001 1:01 am
Location: McKinney, Tx

Postby olly » Sun Jul 31, 2005 3:12 am

Sounds like the password and/or username you're using to connect to the database is wrong. Or you need to tweak with the account settings of your database system
olly
Green Belt
Green Belt
 
Posts: 222
Joined: Thu Jun 27, 2002 8:11 pm

Postby hotfox5 » Wed Dec 07, 2005 2:48 pm

Create a UDL file based on you MSSLQ connection then you will know if your connection string works
"God didn't create Rambo. I created him... "

me @ www.....
hotfox5
Initiate
Initiate
 
Posts: 72
Joined: Sat Jun 21, 2003 8:26 pm
Location: Hopefully near that chick above this, love that mask

Postby Roach412 » Wed Dec 07, 2005 8:00 pm

the specific user that you're attempting to access with...do they have persmissions on the hardware that's running the server? what are you running this on? VB? ASP? C#? what versions? this all can be very helpful. :D

-Roach
Lian Li Lancool First Knight Series PC-K59W
Intel Core i7-960 Bloomfield 3.2GHz
EVGA X58 FTW3 132-GT-E768-TR
EVGA GeForce GTX 1070 FTW GAMING ACX 3.0
G.SKILL Ripjaws Series 12GB (3 x 4GB)
Crucial M4 128gb SATAIII SSD x2
Crucial M4 256gb SATAIII SSD
OCZ Saber 1000 960GB Enterprise SSD
Corsair Professional Series HX850 PSU
Dell UltraSharp U2713HM 27" w/drop ceiling mount
Logitech G930 7.1 Headset
DBPOWER RGB LED Keyboard
Logitech G402 Hyperion Fury
Roach412
Black Belt 2nd Degree
Black Belt 2nd Degree
 
Posts: 2718
Joined: Mon Aug 09, 2004 7:33 pm
Location: Milwaukee - Wisconsin

Postby olly » Thu Dec 08, 2005 10:37 am

Looks like java to me. Use a try catch for the sql exception. if its .NET it will be similar.

Code: Select all
try
{
  //Your database stuff here
}
catch (SQLException e)
{
   // handle error processing
}


It looks like your username and password are not being found in the database so you need to write some elegant error handling for such an occurence.
olly
Green Belt
Green Belt
 
Posts: 222
Joined: Thu Jun 27, 2002 8:11 pm


Return to Programming

Who is online

Users browsing this forum: No registered users and 1 guest