Connecting to Firebird (ODBC)

www.altova.com Print this Topic Previous Page Up One Level Next page

Home >  Connecting to a Database > Database Connection Examples >

Connecting to Firebird (ODBC)

This topic provides sample instructions for connecting to a Firebird 2.5.4 database running on a Linux server.

 

 

Prerequisites:

The Firebird database server is configured to accept TCP/IP connections from clients.
The Firebird ODBC driver must be installed on your operating system. This example uses the Firebird ODBC driver version 2.0.3.154 downloaded from the Firebird website ( https://www.firebirdsql.org/ ).
The Firebird client must be installed on your operating system. Note that there is no standalone installer available for the Firebird 2.5.4 client; the client is part of the Firebird server installation package. You can download the Firebird server installation package from the Firebird website ( https://www.firebirdsql.org/ ), look for "Windows executable installer for full Superclassic/Classic or Superserver". To install only the client files, choose "Minimum client install - no server, no tools" when going through the wizard steps.

Important:

 

The platform of both the Firebird ODBC driver and client (32-bit or 64-bit) must correspond to that of DiffDog.
The version of the Firebird client must correspond to the version of Firebird server to which you are connecting.
You have the following database connection details: server host name or IP address, database path (or alias) on the server, user name, and password.

 

 

To connect to Firebird via ODBC:

1.Start the database connection wizard.
2.Click ODBC Connections.
3.Select User DSN (or System DSN, if you have administrative privileges), and then click Add DSN_add .

firebird_odbc_driver

4.Select the Firebird driver, and then click User DSN (or System DSN, depending on what you selected in the previous step). If the Firebird driver is not available in the list, make sure that it is installed on your operating system (see also Viewing the Available ODBC Drivers ).

firebird_odbc_setup

5.Enter the database connection details as follows:

 

Data Source Name (DSN)

Enter a descriptive name for the data source you are creating.

Database

Enter the server host name or IP address, followed by a colon, followed by the database alias (or path). In this example, the host name is firebirdserv, and the database alias is products, as follows:

 

firebirdserv:products

 

Using a database alias assumes that, on the server side, the database administrator has configured the alias products to point to the actual Firebird (.fdb) database file on the server (see the Firebird documentation for more details).

 

You can also use the server IP address instead of the host name, and a path instead of an alias; therefore, any of the following sample connection strings are valid:

 

firebirdserver:/var/Firebird/databases/butterflies.fdb

127.0.0.1:D:\Misc\Lenders.fdb

 

If the database is on the local Windows machine, click Browse and select the Firebird (.fdb) database file directly.

Client

Enter the path to the fbclient.dll file. By default, this is the bin subdirectory of the Firebird installation directory.

Database Account

Enter the database user name supplied by the database administrator (in this example, PROD_ADMIN).

Password

Enter the database password supplied by the database administrator.

 

6.Click OK.

© 2019 Altova GmbH