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



When you submit the job as you have in your example, the numberic values
are converted to 15,5 packed.  All you have to do is define your
parameters as 15,5 packed in the RPGLE program and you won't bomb.

Marvin


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Dan Bale
Sent: Tuesday, July 20, 2004 10:26 AM
To: midrange-l@xxxxxxxxxxxx
Subject: Parameter decimal-data error on submitted program

I'm hitting a serious brain fade here.  FWIW, we're on v5r2.

I have a CL program that has two numeric values.  The CL program then
submits a job, calling an RPGLE program with those numeric fields as
parameters.  The RPGLE program bombs with a decimal-data error.  The
dump
shows the two values as having hex zeros.

When I change the CL program to call the RPGLE program directly using
the
same parameters, and not submit it, it works fine.  (See example code
below.)

Is SBMJOB doing something to those numeric parameter values?

tia,
db


Pgm
      Dcl   &p_Month    *Dec  (     2  0 ) Value( 01 )
      Dcl   &p_Year     *Dec  (     4  0 ) Value( 2004 )

      SbmJob     Cmd( Call ARR101CTSR +
                   Parm( &p_Month &p_Year ))

      Call ARR101CTSR   Parm( &p_Month &p_Year )
Endpgm

ARR101CTSR:

  d Date            s              7  0
   * Entry parameters
  d p_Month         s              2  0
  d p_Year          s              4  0

  c     *Entry        Plist
  c                   Parm                    p_Month
  c                   Parm                    p_Year

  c                   Eval      Date = ( p_year - 1900 ) * 10000 +
  c                                           p_month * 100 + 01
  c                   Eval      *inLR = *On
  c                   Dump

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-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.