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



You need the AS400Bin4 object then. Just Google for it and you will see
plenty of examples.

Since though you say SQL is already able to call it, why can't you just call
it from SQL via JDBC?
--
James R. Perkins
http://twitter.com/the_jamezp


On Tue, Oct 27, 2009 at 16:29, Loyd Goodbar <loyd@xxxxxxxxxxxxxx> wrote:

Dan,

The numeric in RPG is definitely 10i 0 (integer, 4b0, etc.).

d incgljseq pr extpgm('INCGLJSEQ')
d inlocation 5a const
d outuseseq 10i 0

I used a prototype instead of *ENTRY PLIST.

A testing program and SQL external procedure both call this program
successfully. Due to other limitations (unrelated to RPG or Java), I need
to
call the program from Java.

Thanks,
Loyd

2009/10/27 Dan Kimmel <dkimmel@xxxxxxxxxxxxxxx>

If you are using a numeric field from RPG most likely it is
AS400ZonedDecimal or AS400PackedDecimal. From your description of the
characters, I'd bank on packed. Probably 3/0 (three positions, zero
decimal
positions). Something like this

BigDecimal result = (BigDecimal)new
AS400PackedDecimal(3,0).toObject(parmList[0].getOutputData());

I'm working from memory here, but I believe the java object returned by
the
toObject of AS400PackedDecimal is BigDecimal.


--
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-Ups:
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.