Stelo Technical Documents

Using StarSQL for Java with DBeaver

Last Update: 20 October 2022
Product: StarSQL for Java
Version: 2.5 or later
Article ID: SQV00SJ015

Abstract

DBeaver is a Java-based universal database tool for developers, DBAs and analysts. It can be used on all major operating systems, accessing a wide range of databases.

The StarSQL for Java JDBC driver can be used with DBeaver to access DB2 data. This document explains how to configure DBeaver to use StarSQL for Java.

Solution

  1. Install StarSQL for Java. Note the install location (e.g. C:\Program Files (x86)\StarQuest\StarSQL_Java\ on 64-bit Windows; /usr/share/starsql_java on Linux).
  2. Configure StarSQL for Java licensing: edit StarLicense.properties and/or configure licensing with the License Configuration application, or create a DNS name starlic pointing to a StarLicense server. You can use one of the supplied sample applications to verify licensing. See Licensing for additional information.
  3. Start the Driver Manager dialog using the Database->Driver Manager menu choice.
  4. Click the New button to add a new driver.
    1. Enter the following information:
      Driver Name: StarSQL for Java
      Driver Type: Generic
      Class Name: <automatically filled in when you click Find Class in the next step>
      URL template: leave blank

  5. Select the Libraries panel, select Add File, and browse to the location of StarSQL_JDBC.jar
  6. Click Find Class and select the Class Name displayed (com.starsql.jdbc.SQDriver)



  7. Return to the Settings panel and verify that the Class Name has been populated.



  8. Click OK to exit Driver Manager setup.
  9. Create a connection using the Database->New Connection menu choice.
  10. Select StarSQL for Java.
  11. Enter the JDBC URL, Username & Password and Test the Connection:



  12. If you wish to specify any of the optional StarSQL for Java connection properties such as collection (location of the StarSQL packages), you can specify them on the JDBC URL, or enter them on the Driver Properties panel:

     

    Licensing

    To license StarSQL for Java for use with DBeaver, do of the following:

  • Copy or link StarLicense.properties to the DBeaver plugins subdirectory:
    On Windows, in an elevated command window:
    mklink "C:\Program Files\DBeaver\plugins\StarLicense.properties" "C:\Program Files (x86)\StarQuest\StarSQL_Java\StarLicense.properties"

    On Linux:
    ln -s /usr/share/starsql_java/StarLicense.properties /opt/DBeaver/plugins

    OR
  • Create a DNS entry starlic, pointing to a StarLicense server, either on your DNS server or in your local hosts file (\Windows\System32\drivers\etc\hosts or /etc/hosts).

     



DISCLAIMER

The information in technical documents comes without any warranty or applicability for a specific purpose. The author(s) or distributor(s) will not accept responsibility for any damage incurred directly or indirectly through use of the information contained in these documents. The instructions may need to be modified to be appropriate for the hardware and software that has been installed and configured within a particular organization.  The information in technical documents should be considered only as an example and may include information from various sources, including IBM, Microsoft, and other organizations.