cancel
Showing results for 
Search instead for 
Did you mean: 

JDBC Adapter: Deploying Multiple Database Drivers

Former Member
0 Kudos

Hi Experts,

We are currently connecting multiple database servers (SQL, Oracle 11g and 8i) in PI 7.30. As a prerequisite, database drivers are to be included in deployment (which is already been followed from the documentations provided). From my understanding, it won't cause any conflict as long a the .jar file is not the same from the one that is included in .sda.

Connecting SQL server (sqljbc4.jar) and Oracle 11g (ojdbc6.jar) don't have any problem. I have included classes12.jar and ojdbc14.jar and will be connecting to JDK 1.3.1_13 (JDK 1.3). I'm currently facing an issue in which upon connecting the oracle server, which is

Unable to create new pooled resource: DriverManagerException: Cannot establish connection with the registered driver. oracle.jdbc.driver.OracleDriver returns: 7. : ArrayIndexOutOfBoundsException: 7

Tried restarting JAVA stack and tested the connection but no luck.

Searched some answered concerns above but it all refers on links on HOW TO DEPLOY JDBC adapter, which doesn't help at all since.

Any ideas on how check or did I deploy something that made the those drivers coflict?

Cheers,

R-jay

Accepted Solutions (1)

Accepted Solutions (1)

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Your JDK Version should be 1.5+.  PI 7.1  onwards supports 64 bit os. You need to upgrade java version to 1.5 for handling the oracle as well PI 7.3

Former Member
0 Kudos

Hi Baskar,

Just to confirm from your end base on your answer. I should be updating the Server that hosts Oracle 8i to JDK 1.5 Since I have to consider my PI's JDK which is 1.6, am I correct?

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Yes that is correct. JDBC drivers (java version that runs java compiled driver classses) on PI 7.3 should match with oracle server jvm.  I don't know whether your oracle 8i can run on java 1.5+.

Former Member
0 Kudos

Thanks for your helpful insight Baskar. I'll to update the JDK of Oracle 8i (up to which version of JDK is capable of it - otherwise, upgrade to Oracle 11g).

I'll update this thread on the outcome of my tests. Thanks!

bhavesh_kantilal
Active Contributor
0 Kudos

Hello Jay,

Did you make progress on this? Did you get around to getting PI 7.3 connect to both Oracle 11g and Oracle 8i DB's?

We have the same issue and are trying to figure out the best driver for this. Appreciate if you can share your findings.

Regards,

Bhavesh

Former Member
0 Kudos

Hi Bravesh,

Just my insight from the experience I have on this. Oracle 11g supports JDK up to 1.6 - ojdbc6 which is possible for oracle driver deployment in PI 7.30 but Oracle 8i only supports JDK up to 1.4 - ojdbc14.jar (I think when I read some note 831162 section 10) in which upgrading it to JDK 1.6 is not possible (correct me if I'm wrong),

So technically speaking from my own experience in connecting to both version is not possible. I tried deploying several combination of drivers like (ojdbc6 + ojdbc14; ojdbc6 + classes12.jar) but didn't work. Once drivers are deployed, PI 7.30 only takes ojdbc6.jar driver parameters as it fits to its JDK version which is 1.6 so lower version of drivers is be disregarded.

To summarize, the only possible solution to this is to have Oracle 8i upgraded to 11g. But for my current setup, we did maintain two middlewares (XI - connecting oracle 8i and PI - connecting oracle 11g) up until my client will be upgrade their oracle8i to oracle 11g. Maintaining 2 middleware systems is not a best practice but it will be a temporary workaround until they'll upgrade it.

Hope it helps.

Cheers,

R-jay

bhavesh_kantilal
Active Contributor
0 Kudos

Hello Jay,

Appreciate your response. My research so far has also pointed me to the same direction that Connecting PI 7.3 to a Oracle 8i DB might not be possible.

Ofcourse going to either Oracle or SAP would not help as 8i is out of support.

In our case we have a challenge that we plan to perform a Upgrade rather than Migration and hence having parallel landscapes is ruled out. Guess while the 8i DB is being upgraded we might have to work on a interim solution.

Thanks Once Again.

Regards,

Bhavesh

bhavesh_kantilal
Active Contributor
0 Kudos

We have just 1 Interface that connects to a Oracle 8i Database. We plan to look at a option to use a Native Connection directly to the Database from a User Defined Function for the same while the DB is being upgraded. Load the Classes12.zip into Imported Archives and then use the corresponding classes for the Connection.

While I am not sure if this will work, plan to give it a shot. Will keep you updated.

Regards,

Bhavesh

bhavesh_kantilal
Active Contributor
0 Kudos

Hello Ray,

We managed to crack this.

1. We created a DataSource in NWA and used ojdbc14.jar in the DataSource.

2. Modified our Lookup UDF to use the DataSource connection rather than the JDBC Adapter.

As we use the Oracle 8i DB for XREF / Lookup, this does the trick ( for now ) till we upgrade the DB.

Regards,

Bhavesh

Former Member
0 Kudos

Wow, that's good news! At least with this scenario we can say that we connect Oracle 8i with PI 7.30 through this interim solution.

Good Job Bravesh!

Cheers,

R-jay

Former Member
0 Kudos

Just in case some one is facing a similar issue and want a elegant solution.

We had a very similar scenario where we needed to connect with Oracle 8 and Oracle 11 db. We solved the issue by writing a small wrapper class around the JDBC driver. The program gets the version from the driver using (driver.getMajorVersion()) and if it is less than 10 it returns the ojbc 14.jar driver to the Driver Manager else the normal processing which return the default driver.

We have bundled the ojdbc14.jar along with this new program and deployed this as a SDA.

Former Member
0 Kudos

Dear JaiShankar,

did you publish your solution somewhere in SCN? Or ist it possible to receive your solution and the example coding per mail?

Thanks in advance!

Daniel

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi

Java Version on PI 7.3 and Database  side java version should be same .