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



Hi,

just put the jar with the Driver anywhere, you want and add the jar to the 
classpath. You could call your program from a CL like this:
 PGM
     DCL   &CMD  *CHAR (256)
     CHGVAR &CMD (                                                   +
              'java -classpath '                                  !! +
            /* your application directory or jar              */+
              '/home/bender/java:'                                !! +
            /*  your MSSQL driver              */+
              '/yourPath/yourDriverclasses.jar:' !! +
            /* the toolbox driver               */+
              '/QIBM/ProdData/HTTP/Public/jt400/lib/jt400.jar'    !! +
            /* your mainClass                */+
            /* myMainClass            */+
                 )
     SBMJOB CMD(                                                     +
                QSH CMD(                                             +
                        &CMD                                         +
                       )                                             +
               )                                                     +
            JOB(MSSQLSTUFF)
ENDPGM

I would not recommend to use any plstform dependent stuff, if not really 
needed.

Dieter

On Donnerstag, 20. Mai 2004 06:51, John Gilmore-Baldwin wrote:
> I'm writing a small java program that will be called from a CL. It
> accesses MSSQL server to compare data against a file on the iSeries.
>
> Where should I put the jdbc driver? On other platforms, I've put the
> driver in the java extensions directory, but "Q" directories are
> supposed to be off limits for user stuff (hence
> /QIBM/UserData/Java400/ext/ can't be used). Is there a ext directory I
> can use?
>
> In the interim, I've added the jdbc driver classes into my program's
> jar file to work around the problem. But a couple of specific
> questions:
>
> 1. If I avoid my workaround and avoid the /QIBM directories, no matter
> what I do with classpath, I always get an error "No suitable driver
> found" when I try to connect to MSSQL. What is the right way to set
> classpath?
>
> 2. What is the difference between UserData and ProdData in the /QIBM
> directory?
>
> Sorry if this is documented and I'm missing it. I'm fairly new to java
> on iSeries. Any pointers to documentation are most welcome.
>
> John Gilmore-Baldwin
>
> _______________________________________________
> 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.

-- 
mfG

Dieter Bender


DV-Beratung Dieter Bender
Wetzlarerstr. 25
35435 Wettenberg
Tel. +49 641 9805855
Fax +49 641 9805856
www.bender-dv.de
eMail dieter.bender@xxxxxxxxxxxx


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.