Menu

driver parameters Log in to Edit

marsupilami79

Scope

Most or all Zeoslib drivers accept more parameters than can be adjusted in the TZConnection object. These parameters can be set in the TZConnection.Properties property. Each line contains one parameter and possibly one value for that parameter: <parametername>[=<parametervalue>]</parametervalue></parametername>

This document tries to document these additional parameters for the Zeoslib drivers. This is work in progress. If you need any more information than is provided here, don't hesitate to have a look at the source code or ask a question at the forums.

PostgreSQL

This driver has several subdrivers that should also take the parameters listed here. These drivers are postgresql, postgresql-7, postgresql-8, postgresql-9. They accept the following parameters:

beginreq:

oidasblob

Undefined_Varchar_AsString_Length: Undefined_Varchar_AsString_Length = <maxlength>
PostgreSQL allows to define varchar fields without a length limit. Usually Zeos will treat these fields as Memo fields. This makes these fields unusable with TDBEdit components. If you specify this parameter Zeos will treat these filsd as if they had a length limit of <maxlength></maxlength></maxlength>

CheckFieldVisibility

NoTableInfoCache: NoTableInfoCache
The PostgreSQL driver has an internal cache for table metadata. This should require less queries to the system tables for table metadata and so increase speed when using PostgreSQL via slow lines or VPNs or even just the Internet. But if you change the layout of your database during normal operation you might want to disable this cache by specifying this parameter.

sslmode, requiressl, sslcompression, sslcert, sslkey, sslrootcert, sslcrl: These parameters control the use and behaviour of SSL when connecting to your PostgreSQL database. Please check the chapter about SSL Support of libpq for documentation on how to use these parameters.

timeout: timeout = <time>
This will set the connection timeout to <time> seconds. A value of 0 will disable the timeout.

application_name: application_name = <appname>
This parameter allows one to set the application name displayes in various PostgreSQL outputs. Only printable ASCII characters may be used for the value.</appname>

standard_conforming_strings

SQLite

This driver has several subdrivers that should also take the parameters listed here.

foreign_keys: This parameter will enable or disable the foreign keys checking of SQLite. Set it to t/true/y/yes/any interger <> 0 to enable it. Any other value will disable it. Omitting the parameter will stick to the compile time default of your SQLite library.

FreeTDS / mssql / sybase

These drivers support Microsoft SQL Server and SAP Adaptive Server Enterprise, the former Sybase Adaptive Server Enterprise. Use of the mssql driver is discouraged because it requires the ntwdblib.dll that is not supported by Microsoft anymore. Choose FreeTDS in that case. Also Sybase doesn't provide a 32 bits client library with current products. In that case you probably also want to choose FreeTDS. Some binary files for FreeTDS can be found in the Zeos File repository although they are not guaranteed to be current. For a current driver you probably want to read the article about compiling FreeTDS yourself in this Wiki.

Known Bug for SAP/Sybase ASE: Zeos uses the sp_jdbc_columns system stored procedure to get meta data information about table columns. This stored procedure cannot be used in an explicit transaction. This can lead to exceptions, if the table metadata is not already in the Zeos metadata cache. This behaviour was seen in ASE 12.5 and it was not seen anymore in ASE 16. On Versions inbetween them your mileage might vary.
Setting UseMetadata in the TZConnection Object will disable the use of metadata by Zeos. In this case you will probably end up with read only datasets and need to provide TZUpdateSQL objects for making them writable again.

Parameters

Common Parameters:

workstation: workstation=<workstationname>
The workstation name to send to the server.</workstationname>

appname: appname=<applicationname>
The application name to send to the server.</applicationname>

language: language=<languagename>
The language the server should use for messages.</languagename>

timeout: timeout[=<timeoutseconds>]
The login timeout to use in seconds.</timeoutseconds>

ResetCodePage: Don't use this parameter if don't know what you do.

ANSI_PADDING: ansipadding=<paddingenable>
if you set paddingenable to t/true/y/yes/any integer <> 0 or ON Zeos will set the ANSI_PADDING feature of your Server to on. The default is to set ANSI_DEFAULTS and ANSI_PADDING to off.</paddingenable>

FreeTDS specific parameters:

log / logging / tds_dump: <log|logging|tds_dump>=<value>
Setting this parameter to t/true/y/yes/any interger <> 0 will enable the FreeTDS logging festure. Use the parameter logfile / log_file / tds_dump_file to set the desired path of your log file. If you don't provide a log file name, Zeos will use your application name and create a log file with that name and the extension tdslog.</value></log|logging|tds_dump>

codepage: codepage=<codepagename>
Using this parameter with Microsoft SQL Servers you can tell FreTDS which codepage to use when communicating to your program. The communication between FreeTDS and Microsoft SQL Server will still be in UTF-16 but FreeTDS will convert that to the codepage of your choice. If you are in doubt simply use UTF-8. You should be aware that FreeTDS will need libiconv support for any other encoding than UTF-8 and ISO8859-1.</codepagename>

Note on Windows trusted authentication: You can use FreeTDS to login with integrated / trusted Windows authentication. Simply keep the user name and the password empty to do so.

mssql specific parameters:

NTAuth / trusted / secure: <NTAuth|trusted|secure>
Using this parameter will keep Zeos from specifying a username and password when connection to the SQL Server. Trusted Authentication is used in that case.

sybase specific parameters:

codepage: codepage=<codepagename>
This parameter will tells the sybase driver which codepage you want to use when communicating to the server.</codepagename>

interbase / firebird

These drivers support the Embarcadero / Inprise / Borland Interbase servers as well as Firebird Servers. Use the interbase driver if you have an Interbase database. Use the firebird-* drivers if you want to connect to Firebird Servers.

Parameters

WireCompression: WireCompression=<enable>
Setting this parameter to t/true/y/yes/any interger <> 0 will enable the wire compression in Firebird 3.0 and above.</enable>

MariaDB / MySQL

Using Named Pipes on Linux

Set the following parameters in the TZConnection.Properties property:

MYSQL_OPT_NAMED_PIPE
MYSQL_OPT_PROTOCOL=3

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.