Using the JDBC IDM Driver with Custom Descriptor Files


The IDM JDBC driver is one of the more powerful drivers in the current set of drivers. It can connect potentially to any database that has a JDBC interface. As a consequence it is has some of the more complex setup since there are so many possibilities.

One thing that comes up is the need to customize the drivers behavior to match your site's peculiar environment. The docs describe this process pretty well.

Each major database type (Oracle, MySQL, MS-SQL, DB2, etc.) has some default configurations that work most of the time out of the box. But you may have the need to tweak some things for your setup.

If you look at the JDBCConfig.jar file (typically in the lib directory on the Remote Loader server), you will see that it contains a stack of JAR files, usually named similar to _databaseName_something.xml. There is a set for each major database type. You tell the driver which database type you are using during the configuration, and it reads the appropriate set of configuration files at load time.

If you need your own custom set, for example to map a syntax type of DATE to TIMESTAMP, you need to edit the _oracle_jdbc.xml file as an example. The docs recomend that you name the file without the leading underscore, because those are reserved for the default files.
Then you make a JAR from it (keep the path as in the shipping version) and name the file anything that starts with JDBC (any case is OK).

You will get an error if you duplicate an existing file name in the shipping version (thus, you should not reuse the _oracle_jdbc.xml name - make sure it is unique to your site) and it will not actually load at first.

To fix this,

1. In the driver configuration, enable Show Compatability Parameters.

2. Set "Use custom descriptor files" to Yes.

3. In the "jdbc-descriptor:" field, specify just the file name of the custom descriptor you created. Do not specify the path to the JAR or the "com\novell\..." path inside the JAR - just use the "oracle_custom_file_I_made.xml" or whatever you called it).

Then it will load.


How To-Best Practice
Comment List
  • Amusingly, 12 years later I had to use the info in this article. I knew I had written about it, and could only remember one word, but was able to search and find it. Best solutiions are when I search for a problem and find out I wrote an answer for it 10 years ago and forgot it.