Re: Login failed for user 'sa'. C#, SqlServer 2000



If you're currently setup for SqlServer and Windows authentication then use
Query Analyzer to login using sa and your password for sa.
If you get the same problem then SQL Server isn't setup for SqlServer
authentication, it's only setup for Windows authentication.

If you're able to login using Query Analyzer then post the actual code (not
just the connection string) that you're using, something is wrong with that
code.



"Shawn K" <ShawnK@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:FE992BB3-9C44-403F-84F8-19FF8CE2BCFD@xxxxxxxxxxxxxxxx
> This is driving me nuts. I have found plenty of newsgroups that discuss
> this
> subject and not one of them helped. I have tried multiple connection
> strings
> to connect to a database on another computer. The current string
> erver=hostMachine;Database=hostDatabase;User ID=sa;Password=hostPassword
> produces the following error:
>
> Login failed for user 'sa'. Reason: Not associated with a trusted SQL
> Server
> connection.
>
> So I tried another string using "Trusted_Connection=Yes" which produces an
> error that user 'null' was not trusted.
>
> SqlServer is currently setup to use SqlServer and Windows authentication,
> which is why I don't understand why providing the username and password
> for
> the server would return that error. I also double checked and reset the
> password in enterprise manager and that still did not help. I'm at my
> wits
> end so any assistance would be appreciated. Thanks in advance.


.



Relevant Pages

  • Re: Login failed for user sa. C#, SqlServer 2000
    ... > If you get the same problem then SQL Server isn't setup for SqlServer ... it's only setup for Windows authentication. ... >> to connect to a database on another computer. ...
    (microsoft.public.dotnet.framework.adonet)
  • Can ASP.NET 2.0 Use SQLServer 2000 For Membership Function
    ... Can I use SQLServer 2000 with ASP.NET 2.0 instead of SQLServer 2005, ... I've setup my Login page, controls, etc., and now it's time to use the Web ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: data access strategy
    ... there is a domain which is why my app was originally setup to use windows authentication. ... So temporary way is to use the VPN but I'd like to build a module of my app to run on a windows mobile device so I'll keep trying to get remote DB access working......unless this is a really bad idea. ...
    (microsoft.public.sqlserver.connect)
  • Re: Registration from Enterprise Manager
    ... >I have a sqlserver SQLA which I have registered in EM with a sqlserver ... >problem is that when I look at the security log of SQLA, ... >failure audits but with a uid that I am logging in to my local machine with. ... >sending windows authentication requests at the same time. ...
    (microsoft.public.sqlserver.connect)
  • Re: Password require when login into outlook
    ... the (insert latest virus name here) virus, all mail sent to my personal ... After searching google.groups.com and finding no answer, Lillian asked: ... | not windows authentication, ... so how to setup ...
    (microsoft.public.outlook)

Loading