× 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: Java and COBOL stored procedures
  • From: "Richard Dettinger" <cujo@xxxxxxxxxx>
  • Date: Fri, 16 Feb 2001 07:47:50 -0600
  • Importance: Normal


You can't pass an Array as a parameter in Java.  Well, Java 2 has support
for the SQL datatype ARRAY in the getArray/setArray methods, but this is
not the same thing, and the 400 doesn't support ARRAY data types today.

There are ways (which I am not too up on personally) to return an array as
a ResultSet.  I know this can be done from C, I assume it works from other
languages as well.  In that model, the StoredProcedure returns the
ResultSet and then you process it exactly as if it was an open database
cursor coming back.   Perhaps there is a solution somewhere down that path
for you.

Regards,

Richard D. Dettinger
AS/400 Java Data Access Team

"Biologists have a special word for stability -- dead"

                Larry Wall
                Open Source Developers Journal
                Issue 1, Jan  2000


"Richard Casey" <casey_r@popmail.firn.edu>@midrange.com on 02/14/2001
02:49:08 PM

Please respond to JAVA400-L@midrange.com

Sent by:  owner-java400-l@midrange.com


To:   "Java-400 List \(E-mail\)" <JAVA400-L@midrange.com>
cc:
Subject:  Java and COBOL stored procedures



I'm experimenting with calling COBOL stored procedures from Java programs
and have successfully used "getString" to return character variables from
the procedure.
Is it possible to return an array? Or do I have to return a really large
CHAR variable and have the Java program break it up?

On a different note, is there any way for a servlet to call a stored
procedure and pass a reference to the PrintWriter variable, so that the
called program could write directly to the HTML output stream?

Thanks in advance!

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


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.