Login failed for user 'sa'.

Hi Experts,

I know what the error means, I believe that I have done all that is necessary but where else can I look.  I am using dotnet to insert data into the db but it throws up the error above.

thanks


Data Source=DEV2;Initial Catalog=Estates;Integrated Security=False;Persist Security Info=True;User ID=sa;Password=***********;TrustServerCertificate=False;Context Connection=False

Open in new window

test.bmp
SirReadAlotAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Om PrakashCommented:
Is the sa password correct?
Can you login in the SSMS using the sa credentials
SirReadAlotAuthor Commented:
what is ssms?

in dotnet i tested that connection and it works
RiteshShahCommented:
ssms is SQL Server Management studio....

Are you sure SA is not disabled?
The 7 Worst Nightmares of a Sysadmin

Fear not! To defend your business’ IT systems we’re going to shine a light on the seven most sinister terrors that haunt sysadmins. That way you can be sure there’s nothing in your stack waiting to go bump in the night.

SirReadAlotAuthor Commented:
Is the sa password correct?
Can you login in the SSMS using the sa credentials

yes it is correct.

where can i enable SA
TejasShahMscITCommented:
Hi,

You should check sa password from SSMS as seen in attached screenshot.
just make sure that password is valid.

Thanks,

Tejas
SQLYoga.com
ee.JPG
Rajkumar GsSoftware EngineerCommented:
Is your full error message is like shown below ?
"Login failed for user 'sa'. Reason: Not associated with a trusted SQL Server connection"

If so, try this
http://sqlservercode.blogspot.com/2006/02/login-failed-for-user-sa-reason-not.html

Raj
SirReadAlotAuthor Commented:
hi,

test2 is the full details of the error.

in test3, I have noticed that the current password (confirm password) is different from the one used in .net (password)



test2.bmp
test3.bmp
Rajkumar GsSoftware EngineerCommented:
To enable the SA account, execute this

ALTER LOGIN sa ENABLE ;
GO
ALTER LOGIN sa WITH PASSWORD = '<enterStrongPasswordHere>' ;
GO

Raj
SirReadAlotAuthor Commented:
raj...
anyone....

i have alter the password but still not luck
SirReadAlotAuthor Commented:
this is what i have in the appconfig

 <connectionStrings>
        <add name="DataAccessLayer.Properties.Settings.EstatesConnectionString"
            connectionString="Data Source=****;Initial Catalog=Estates;Persist Security Info=True;User ID=sa"
            providerName="System.Data.SqlClient" />
    </connectionStrings>
Anthony PerkinsCommented:
It looks like you are missing your password in your connection string.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
SirReadAlotAuthor Commented:
.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server

From novice to tech pro — start learning today.