Page 1 of 1

How to connect SQLServer2005 with SQL Native Client

Posted: Thu 31 May 2007 07:19
by ayaring_n
I'm a customer.I'm developer of COMPUTER INSTITUTE OF JAPAN.
I bought the MS SQL DBX Driver from you.

I am having some probrems with MS SQL Server 2005 when trying to connect with SQL Native Client.

Using
Programming Software is Delphi7.
dbexpsda.dll version is 3.10.8.0.



My Connection Parameters are under.

----------------------------------------------------------------------
dbsConn: TCRSQLConnection;


with dbsConn do
begin
DriverName := 'SQL Native Client';
GetDriverFunc := 'getSQLDriverSQLServer';
LibraryName := 'dbexpsda.dll';
VendorLib := 'SQLNCLI';

Params.Clear;
Params.Add('Database=MyDatabaseName');
Params.Add('Server=MyPrinciparServer');
Params.Add('FailoverPartner=MyMirrorServer');
Params.Add('UID=Myname');
Params.Add('PWD=MyPassword');
end;

dbsConn.Connected := True;

---------------------------------------------------------------------

I cannot connect Database.
If I do Parameters change
from 'Server' to 'HostName'
from 'UID' to 'User_name'
from 'PWD' to 'password'

I can connect Database.

But, 'FailoverPartner' is not recognized.
So, Even if I do failover, the server is not switched.


How can I resolve my probrem?

Thanks

Aya Nakano

[email protected]

Posted: Thu 31 May 2007 09:09
by Jackson
Use the following parameters to connect to Microsoft SQL Server using DbxSda:
SQLConnection.DriverName := 'SQLServer';
SQLConnection.LibraryName := 'dbexpsda.dll'; // 'dbexpsda30.dll' - for
Delphi 2006 or Turbo products
SQLConnection.VendorLib := 'sqloledb.dll';
SQLConnection.GetDriverFunc := 'getSQLDriverSQLServer';
SQLConnection.Params.Clear;
SQLConnection.Params.Add('User_Name=MyName');
SQLConnection.Params.Add('Password=MyPassword');
SQLConnection.Params.Add('HostName=MyServer');
SQLConnection.Params.Add('Database=MyDatabase');
SQLConnection.Open;

DbxSda uses SQL Native Client by default, if it is installed.
If not, it uses SQL OLE DB Provider for Microsoft SQL Server.
Due to restrictions of the dbExpress technology, there is no possibility to
specify the exact provider to use.
Currently DbxSda doesn't support the "FailoverPartner" parameter.

Posted: Fri 01 Jun 2007 00:49
by ayaring_n
Thank you so much for your response.

----
Aya Nakano

[email protected]