× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Re: Driver for NT SQL Db?
  • From: "Shawn Church" <shawn@xxxxxxxxxx>
  • Date: Wed, 21 Mar 2001 11:45:11 -0600

I have had good luck with DB2 Universal Database for NT, but any database
which provides JDBC drivers should work fine, such as MySQL, etc.  My '400
connects to my NT database routinely, and it works very reliably.  Early on
(about a year and a half ago) I had some problems with the isolation level
which I had to contact IBM database support to resolve (these may not be a
problem in V4R5, but were in V4R4).  Here is a snippet which works (notice
the comments):

    // This is necessary due to a java bug on the AS/400.  If this
    // is not done, we will fail with an SQL package error (bind error).
    Properties db2Properties = new Properties();
    db2Properties.put ("user", "db2admin");
    db2Properties.put ("password", "mypassword");
    db2Properties.put ("transaction isolation", "read uncommitted");
    db2Properties.put ("cursor hold", "false");

   // URL to remote database.  webdata must exist in the AS/400
   // relational database (wrkrdbdire).
    String urldb2 = "jdbc:db2:webdata";

    // The same db2driver class will work for the local db2/400
    // as well as for the remote DB2 UDB database.
    // This is the native driver.  If this code is ported to
    // a non-local host, then the toolkit driver should be used:
    //   Class is com.ibm.as400.access.AS400JDBCDriver",
    //  URL subcomponent is jdbc:as400
    Class.forName("com.ibm.db2.jdbc.app.DB2Driver");

    // Connect to UDB
    db2Conn = DriverManager.getConnection(urldb2, db2Properties);

Shawn

----- Original Message -----
From: "Stone, Brad V (TC)" <bvstone@taylorcorp.com>
To: <JAVA400-L@midrange.com>
Sent: Wednesday, March 21, 2001 10:17 AM
Subject: Driver for NT SQL Db?


> Interested in what driver folks use for attaching to an NT SQL database.
> Any info is appreciated.  For example, one that comes with JDK, or it has
to
> be downloaded, etc.
>
> Right now I'm not worried about speed, I just want to see if I can attach
to
> one on our network.  I am using the "properties" method explained a while
> ago here where I have a db properties file that looks like:
>
> driver=com.ibm.as400.access.AS400JDBCDriver
> url=jdbc:as400://machine
> user=user
> password=password
>
> So Im really looking for something as easy as replacing the driver and url
> properties in the file for the particular machine (I plan on having one db
> properties file for each machine that I want to attach to).
>
> Thanks!
>
> Brad
> +---
> | This is the JAVA/400 Mailing List!
> | To submit a new message, send your mail to JAVA400-L@midrange.com.
> | To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
> | To unsubscribe from this list send email to
JAVA400-L-UNSUB@midrange.com.
> | Questions should be directed to the list owner: joe@zappie.net
> +---
>

+---
| This is the JAVA/400 Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner: joe@zappie.net
+---

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.