× 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.



        Can you please post the code.

        That would be very helpful.

        One thing that everyone has failed to reply to is the fact the
very first lib specified in the libraries property is
        set as default lib. So my unqualified sql statement only looks
for table name in this lib and doesn't search the
        LIBL. How puzzling?? Has anyone encountered this???

        I've now installed JDK1.4.2 and had previously JDK1.2. My java
pgm is called from a RPG.

        How does the system know which version of JVM to start as I've
not specified in any parms or don't know how to in
        RPG.

        Any ideas??? 

Rajesh Anand
Email:Rajesh_anand@xxxxxx


-----Original Message-----
From: java400-l-bounces@xxxxxxxxxxxx
[mailto:java400-l-bounces@xxxxxxxxxxxx] On Behalf Of Marc Nothum
Sent: 29 July 2005 08:19
To: CN=Java Programming on and around the iSeries/O=AS400
Subject: RE: How to use LIBL in connection string.



Hi,


I use the following code to pick up the library-list, as it is in the
AS400-job:

Properties prop = System.getProperties();
libListForm1 = prop.getProperty("java.library.path");

This gives a list in the following format:
/QSYS.LIB/QSHELL.LIB:/QSYS.LIB/CTL.LIB:/Q....

Then:
The string-sequences "/QSYS.LIB/" and ".LIB" have to be removed.
The ":" must be replaced by spaces.

The result is a list in a format to be used in jdbc, as: "QSHELL CTL
QTEMP
QGPL"

If needed, I can supply the code, I wrote to do the transformations.

To use this libl in the jdbc-connection:

Properties connProps = new Properties();
connProps.setProperty("naming", "system");
connProps.setProperty("libraries", libl); //libl is the previously
created
list, as "QSHELL CTL QTEMP QGPL"
connProps.setProperty("user", user);
connProps.setProperty("password", password);
Class.forName(driver);
connection = DriverManager.getConnection(dburl, connProps);


Maybe this helps,

Marc






"Anand, Rajesh" <Rajesh_Anand@xxxxxx>@midrange.com on 28/07/2005
22:27:36

Please respond to Java Programming on and around the iSeries / AS400
       <java400-l@xxxxxxxxxxxx>

Sent by:    java400-l-bounces@xxxxxxxxxxxx


To:    "Java Programming on and around the iSeries / AS400"
       <java400-l@xxxxxxxxxxxx>
cc:

Subject:    RE: How to use LIBL in connection string.


If I use Lib names separated by commas, then will my unqualified
sql will search this libl??

 According to the manual, no. It will assume the first lib as the
default lib for any unqualified sql statement.

 I want to avoid using hard coded libl all together and I want
the unqualified sql statement to search the libl of the
 job calling the Java pgm.

 I think what Ashish is doing is what I want to achieve. Just
thought it might be possible to specify the user libl in
 the connection string.

 maybe not!!!

 rgds,

Rajesh Anand
Email:Rajesh_anand@xxxxxx


-----Original Message-----
From: java400-l-bounces@xxxxxxxxxxxx
[mailto:java400-l-bounces@xxxxxxxxxxxx] On Behalf Of Franco Biaggi
Sent: 28 July 2005 19:20
To: Java Programming on and around the iSeries / AS400
Subject: Re: How to use LIBL in connection string.


This work fine from long time ago:

DatabaseURL=jdbc:as400://10.1.1.1;transaction
isolation=none;naming=system;libraries=lib1,lib2,qgpl,qtemp;block
size=128;extended dynamic=true;package=MYPKG;package cache=true;package
library=qgpl

--
This is the Java Programming on and around the iSeries / AS400
(JAVA400-L) mailing list
To post a message email: JAVA400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.
--------------------------------------------------------

If you are not an intended recipient of this e-mail, please notify the
sender, delete it and do not read, act upon, print, disclose, copy,
retain
or redistribute it. Click here for important additional terms relating
to
this e-mail.     http://www.ml.com/email_terms/
--------------------------------------------------------

--
This is the Java Programming on and around the iSeries / AS400
(JAVA400-L)
mailing list
To post a message email: JAVA400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/java400-l.




As an Amazon Associate we earn from qualifying purchases.

This thread ...


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.