Loading the HCL OneDB JDBC Driver
The Driver uses an automatic registration mechanism when you load the driver into your application. You should not need to manually execute any programming logic to 'load' the driver. However if you wish to do so you may
To load HCL OneDB™ JDBC
Driver, use the
Class.forName() method, passing in the OneDBDriver class name.
try { Class.forName("com.onedb.jdbc.OneDBDriver"); } catch (Exception e) { System.out.println("ERROR: failed to load OneDB JDBC driver."); e.printStackTrace(); return; }
The Class.forName() method loads the HCL OneDB implementation of the Driver class, OneDBDriver. OneDBDriver then creates an instance of the driver and registers it with the DriverManager class.