How to connect to ms sql server?

The offical for ZeosLib 7.3 Report problems, ask for help, post proposals for the new version of Zeoslib 7.3/v8
Quick Info:
-We made two new drivers: odbc(raw and unicode version) and oledb
-GUID domain/field-defined support for FB
-extended error infos of Firebird
-performance ups are still in queue
In future some more feature will arrive, so stay tuned and don't hassitate to help
Post Reply
RaelB
Fresh Boarder
Fresh Boarder
Posts: 1
Joined: 11.08.2024, 21:59

How to connect to ms sql server?

Post by RaelB »

Hi,

Can someone explain how to connect to MS SQL Server?
I have selected mssql protocol, and filled in the other required fields (database name, user, pass, hostname). When I try to connect I get this error:
None of the dynamic libraries can be found or is not loadable: ntwdblib.dll, sybdb.dll !
I have a version of sql server installed on the pc as well as some odbc / oledb drivers (as in image below), however neither of the above 2 dlls are found on the pc.

Image

I am trying to connect to a sql server on the internet..

Thanks
marsupilami
Platinum Boarder
Platinum Boarder
Posts: 1956
Joined: 17.01.2011, 14:17

Re: How to connect to ms sql server?

Post by marsupilami »

Hello RaelB and welcome to the forums :)

Zeos has several options for connecting to a MS SQL Server
  • Use the mssql driver: This driver uses FreeTDS to connect to SQL Server. Since you want to connect over the Internet, you most probably need TLS support. FreeTDS uses OpenSSL for TLS support. OpenSSL doesn't use the windows certificate store but expects a set of files in a standard location. Setting this up could be a small challenge. FreeTDS builds can be found in the Zeos download section and in the AppVeyor history for FreeTDS. FreeTDS builds by Zeos are done using MSYS2 and generally don't depend on DLLs that are not part of the zip file. AppVeyor builds depend on the Visual C++ Runtime. OpenSSL libraries are not part of the AppVeyor build artifacts.
  • Use the OLEDB or ODBC driver: These drivers are new in Zeos 8 and give better performance than the FreeTDS driver. They require you to install Microsoft OLEDB or ODBC drivers for SQL Server. Microsoft recommends these drivers as the official way to connect to SQL Server. To use one of these drivers just selet them and put a correct connection string in the database property of TZConnection.
  • The ADO driver: Zeos has a bridge for ADO. It still works but since ADO is deprecated by Microsoft, we also deprecated ADO in favor of OLEDB and ODBC. Basically it works like the OLEDB driver: Put the correct connection string in the database property and it should work.
I hope this helps,

Jan
Post Reply