ODBC access

G

Glenn Robinson

Hello,

I'm writing some java code that reads data from a DB2 table on an IBM
iSeries which is then used to update a Clipper database on a Windows
server.

We have been instructed that the majority of the code needs to run on the
iSeries where the DB2 database exists and as little as possible on the
Windows server.

The ODBC driver that is supplied with Windows has the capability to access
the .DBF files used by Clipper so I am planning to use that to read/write
the Clipper database.

If my java class is running on the iSeries server then what's the best way
of accessing the ODBC driver on the remote Windows server?

I have considered using sockets to pass the data between two java classes
and also looked at RMI.

Any comments on using these approaches?

Is there another way of doing this?


Thanks
 
O

Oscar kind

Glenn Robinson said:
The ODBC driver that is supplied with Windows has the capability to access
the .DBF files used by Clipper so I am planning to use that to read/write
the Clipper database.

If my java class is running on the iSeries server then what's the best way
of accessing the ODBC driver on the remote Windows server?

With a JDBC-ODBC bridge (essentially a JDBC driver). See:
http://java.sun.com/j2se/1.4.2/docs/guide/jdbc/getstart/bridge.doc.html

I have considered using sockets to pass the data between two java classes
and also looked at RMI.

Any comments on using these approaches?

I don't know if RMI is possible, but direct access is an option. It's a
horrible option IMHO, because it's much easier to use a JDBC-ODBC bridge to
access toe ODBC driver. See above.


kind regards,
Oscar
 
G

Glenn Robinson

Oscar kind said:
With a JDBC-ODBC bridge (essentially a JDBC driver). See:
http://java.sun.com/j2se/1.4.2/docs/guide/jdbc/getstart/bridge.doc.html



I don't know if RMI is possible, but direct access is an option. It's a
horrible option IMHO, because it's much easier to use a JDBC-ODBC bridge to
access toe ODBC driver. See above.


kind regards,
Oscar

--
Oscar Kind http://home.hccnet.nl/okind/
Software Developer for contact information, see website

PGP Key fingerprint: 91F3 6C72 F465 5E98 C246 61D9 2C32 8E24 097B B4E2

I did look at this but didn't think it allowed what I wanted.

So, your saying that using the JDBC-ODBC bridge I can run my Java code on
one server and use the ODBC driver located on another server?
 
O

Oscar kind

Glenn Robinson said:
I did look at [the JDBC-ODBC bridge] but didn't think it allowed what
I wanted.

So, your saying that using the JDBC-ODBC bridge I can run my Java code
on
one server and use the ODBC driver located on another server?

My mistake: I forgot that you're trying to access an ODBC driver as if it
were a database. AFAIK this is not possible.

However, the link I posted also refers to this site:
http://servlet.java.sun.com/products/jdbc/drivers

Here you can find database drivers for any kind of database, among which
Clipper.


kind regards,
Oscar
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,577
Members
45,052
Latest member
LucyCarper

Latest Threads

Top