Getting Started with OpenLink’s JDBC–to–ODBC Bridge Driver

Connecting JDBC-compliant applications to ODBC-accessible data sources remains an important requirement for many brownfield enterprise projects. Naturally, these kinds of projects ultimately boil down to the use of open standards based data-flow as a critical component, as with all pursuit of enterprise agility.

JDBC Type (Single-Tier) Driver Architecture Diagram

In this post I cover the installation and configuration of our sophisticated high-performance Lite Edition JDBC Drivers for ODBC Data Sources (also known as the Lite Edition JDBC–to–ODBC Bridge, or simply the JDBC-ODBC Bridge) for Mac OS X.

Before You Install

You must have the following at your disposal:

  • Functioning ODBC DSN (i.e., a DSN which can connect and execute SQL queries, without firewall or other interference)
  • Username and Password credentials for authentication when establishing the ODBC (or soon, JDBC) data connection

Note: You will not be able to use the JDBC-ODBC Bridge driver without having satisfied these conditions.

Obtain a Free Trial License and the Bridge Installer

Visit our License Generator Page, and fill in the License Selection Form:

Initial License Generation Page

Then click on the Generate License button which triggers:

  • Loading of a page with links to the Lite Edition ODBC–to–JDBC Bridge installer archive and associated installation and configuration guides
Installer Archive Download Page
  • Generation and dispatch of an email with a link to the License File you just requested

Note: Please download the license file to your Mac before running the installer.

Software Installation

After downloading the installer package, double-click on its icon, and follow the interaction prompts as and when presented by the installer.

Note: The installer’s prompt to locate your License File is the most important step in this process. Failing to properly install this file will adversely affect usage of these drivers, and can add much complexity to an otherwise simple process.

Testing JDBC Connectivity (Optional)

We provide a simple JDBC application with the JDBC-ODBC Bridge Driver, for testing the JDBC Driver’s installation and basic configuration. The screenshots below will help guide you through the process of establishing a connection using the Lite Edition JDBC Driver for ODBC Data Sources.

Java Environment Issues

To successfully use a JDBC-ODBC Bridge driver, it is important that your target JDBC Driver is properly installed and functioning. You can use our JDBC demo apps (installed with our Drivers) to simplify this process.

macOS

Assuming JDK 1.8,:

  1. Launch Terminal.app
  2. Run cd "/Library/Application Support/OpenLink/Samples/JDBC/jdk1.8\JDBCDemo"
  3. Run sh JDBCDemo.sh
First part of folder tree leading to location of our demo JDBC apps
Second part of folder tree leading to location of our demo JDBC apps
Program initialization using command: sh JDBCDemo.sh
Initial Application Screen with a default JDBC Connection URL in place

Windows

Assuming JDK 1.8:

  1. Navigate to C:\Program Files\OpenLink Software\UDA\Samples\JDBC\jdk1.8\JDBCDemo for 32-bit Bridge Driver with 32-bit JVM on 32-bit Windows, or for 64-bit Bridge Driver with 64-bit JVM on 64-bit Windows; or C:\Program Files (x86)\OpenLink Software\UDA\Samples\JDBC\jdk1.8\JDBCDemo (for 32-bit Bridge Driver with 32-bit JVM on 64-bit Windows. Note: the JDBC-to-ODBC Bridge Driver, the JVM, and the target ODBC Driver must all match in bitness.
  2. Double click on JDBCDemo to start the application

All platforms (macOS, Windows, Linux)

  1. Change the default JDBC connection URL to what’s required by your JDBC Driver.

2. Example JDBC URL for our JDBC-to-ODBC BridgeDriver

3. Enter a sample SQL Query, in this case targeting the Northwind Demo DB schema.

4. Scroll through your query results (which is also a simple test of Scrollable Cursor functionality)

Troubleshooting

License File Location Issues

If you failed to point the installer program to your JDBC-ODBC Driver’s license file, or are upgrading from a Free Evaluation License to a Perpetual License, you will encounter the following error dialog:

OpenLink[JDBC] License not found

This problem is resolved by copying your license from the folder into which it was downloaded into the folder at: /Library/Application Support/openlink/Licenses.

Once the license is in place, you will need to restart the license manager by performing the following steps:

  1. cd "/Library/Application Support/openlink/bin"
  2. sudo ./oplmgr +stop
  3. sudo ./oplmgr +start +directory "/Library/Application Support/openlink/Licenses"

Alternatively, you can use the following sequence:

  1. cd "/Library/Application Support/openlink/Licenses"
  2. sudo ../bin/oplmgr +stop
  3. sudo ../bin/oplmgr +start

Ideally, you should add both the /Library/Application Support/openlink/bin folder to your system PATH and /Library/Application Support/openlink/Licenses folder to the OPL_LICENSE_DIR environment variable by issuing the commands:

export PATH=$PATH:/Library/Application\ Support/openlink/bin ;export OPL_LICENSE_DIR=/Library/Application\ Support/openlink/Licenses ;

And then you can start and stop the License Manager by simply issuing the following commands from any folder location: oplmgr +start and oplmgr +stop, respectively.

Now that access to the License Manager has been configured, you can use the output from the command: sudo ps -ef | grep oplmgr or the system profile manger to confirm the License Manager is up and running.

Activity Manager Snippet Listing OpenLink License Manager

Related

--

--