Cannot log on from a server-application

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
DerPaul
Posts: 17
Joined: Thu 25 Jan 2007 02:35

Cannot log on from a server-application

Post by DerPaul » Thu 24 Jun 2010 10:42

Hi

Whenever I try to log on from a sever-application, I get the following error:
"Login failed for user 'blabla\bla'.
Cannot open database "bla" requested by the login. The login failed."

It happens no matter what database I try to open.
I also tried different databases, and the two different logon-types in Services (Local systemaccount and "This account"), and there are no real differences.

I've made a test-program, and sent it to Dmitri Gerasimenko. Hope its okay.


Hope you can find a solution (Hope there IS a solution?)


Best regards

Poul

Dimon
Devart Team
Posts: 2885
Joined: Mon 05 Mar 2007 16:32

Post by Dimon » Thu 24 Jun 2010 13:57

I can not reproduce the problem.
Please check that you can connect to your SQL Server with the same username, password, and host from any client application (for example SDACDemo).

DerPaul
Posts: 17
Joined: Thu 25 Jan 2007 02:35

Post by DerPaul » Thu 24 Jun 2010 18:31

Hi

After system-logon, I can logon to any database using any valid password.
You can also see that in the logfile in the example I sent you.

The problem isn't logging on to a database as such, it's logging on *before* anyone has logged on to the system, ie. when the Windows login-window is on the screen.

You say that you cannot reproduce the problem. Did you run my example?
That is, install it as a service (ie. run it with the commandline parameters /install), and then restart your Pc?

That's when it won't work.


Best regards

Poul

DerPaul
Posts: 17
Joined: Thu 25 Jan 2007 02:35

Works with ADO

Post by DerPaul » Mon 28 Jun 2010 18:17

Hi

Just wanted you to know this works with ADO.

Poul

Dimon
Devart Team
Posts: 2885
Joined: Mon 05 Mar 2007 16:32

Post by Dimon » Tue 29 Jun 2010 08:40

This problem is connected with the specificity of SQL Server work.
Please copy the ConnectionString property value of the TADOConnection component, that is connected successfully, and set it to the MSConnection.ConnectString property. After this try to test your application.

Post Reply