|
Hi Steve,
(David - it just became RPG!).
The data is being stored in the data area in a packed format. A lot easier to
write a little RPG program to do this instead of the CL. (Following is not
compiled or tested)
D DataArea DS DtaAra(Whatever the Name)
D TheField 9P 0 OverLay(DataArea:33)
D NewValue S 9 0
C *Entry PList
C Parm NewValue
C *Lock In DataArea
C Eval TheField = NewValue
C Out DataArea
C Eval *InLr = *On
HTH
Paul
----- Original Message -----
From: "Raby, Steve (GE Advanced Materials, consultant)" <steve.raby@xxxxxx>
To: "RPG programming on the AS400 / iSeries" <rpg400-l@xxxxxxxxxxxx>
Sent: Tuesday, July 26, 2005 2:13 PM
Subject: RE: CHGDTAARA packed field
> Hello Chaps,
>
> Nope that didn't work, this is what the live one looks like,
>
>
> Value
> Offset *...+....1....+....2....+....3....+....4....+....5
> 0 'AMBISPRD 9902U34274AMB N J ?J32101 '
> 50 ' éh Scholing . . . . . . . . . . . . . . . . . V'
> 100 'oertaal. . . . . . . VO2max. . . . . . . . . . . .'
> 150 ' . . . . . . .111 N '
> 200 ' '
> 250 ' '
> 300 ' '
> 350 ' '
> 400 ' '
>
> and this is the test after that change,
>
>
> Value
> Offset *...+....1....+....2....+....3....+....4....+....5
> 0 'AMBISLNP 9902SUP01 N J00000000100 & '
> 50 ' (1) . . . . . . . . . (2) . . . . . . . . . ('
> 100 '3) . . . . . . . . . (4) . . . . . . . . . (5) . .'
> 150 ' . . . . . . .111 N '
> 200 ' '
> 250 ' '
> 300 ' '
> 350 ' '
> 400 ' '
>
>
> The field starts in position 33, I cannot change the data area as it is part
> of a package so I just need that little bit changed.
>
> Steve
>
>
>
> -----Original Message-----
> From: rpg400-l-bounces@xxxxxxxxxxxx
> [mailto:rpg400-l-bounces@xxxxxxxxxxxx]On Behalf Of Jonathan Mason
> Sent: 26 July 2005 14:32
> To: 'RPG programming on the AS400 / iSeries'
> Subject: RE: CHGDTAARA packed field
>
>
> Hi Steve
>
> I was going to say the same thing as Paul, but he beat me to it :-)
>
> All the best
>
> Jonathan
> www.astradyne-uk.com
>
>
> -----Original Message-----
> From: rpg400-l-bounces@xxxxxxxxxxxx
> [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Paul Tuohy
> Sent: 26 July 2005 13:23
> To: RPG programming on the AS400 / iSeries
> Subject: Re: CHGDTAARA packed field
>
> Hi Steve,
>
> get the boot ready :-)
>
> The data area is a character data area so the VALUE needs to be a
> character
> field.
>
> Try -
> PGM
> DCL VAR(&NUM) TYPE(*DEC) LEN(9 0) +
> VALUE(1)
> DCL VAR(&NUMCHAR) TYPE(*CHAR) LEN(9)
>
> CHGVAR &NUMCHAR &NUM
> CHGDTAARA DTAARA(AMBISDATA (33 9)) VALUE(&NUMCHAR)
> ENDPGM
>
> HTH
>
> Paul
>
> ----- Original Message -----
> From: "Raby, Steve (GE Advanced Materials, consultant)"
> <steve.raby@xxxxxx>
> To: "RPG programming on the AS400 / iSeries" <rpg400-l@xxxxxxxxxxxx>
> Sent: Tuesday, July 26, 2005 12:59 PM
> Subject: RE: CHGDTAARA packed field
>
>
> > Hello Jonathan
> >
> > I just want to change the value to one, I tried just CHGDTAARA from a
> command line, then I put it in a CL,
> >
> >
> > PGM
> > DCL VAR(&NUM) TYPE(*DEC) LEN(9 0) +
> > VALUE(1)
> > CHGDTAARA DTAARA(AMBISDATA (33 9)) VALUE(&NUM)
> > ENDPGM
> >
> > And I get this,
> >
> >
> > Message ID . . . . . . : CPA0701
> > Date sent . . . . . . : 05/07/26 Time sent . . . . . . :
> 13:54:06
> >
> > Message . . . . : CPF1019 received by CHGDTAARA at 500. (C D I R)
> >
> > Cause . . . . . : Control language (CL) program CHGDTAARA in
> library
> > AMBISLNP detected an error at statement number 500. Message text
> for
> CPF1019
> > is: VALUE parameter not correct.
> > Recovery . . . : This inquiry message can be avoided by changing
> the
> >
> > the dump looks like;
> >
> > 5722SS1 V5R2M0 020719 CL Program
> Dump
> > Job name . . . . . . . . : SWRDV027D1 User name . . . . . . . . :
> SUPPORT
> > Program name . . . . . . : CHGDTAARA Library . . . . . . . . . :
> AMBISLNP
> > Messages
> > Message Message
> From
> > Time ID Sev Type Text
> Program
> > 135406 00 CMD 500 - CHGDTAARA
> DTAA
> QCADRV
> > RA(AMBISDATA (33
> 9)) VA
> > LUE(1)
> > 135406 CPF1019 40 ESC VALUE parameter not
> cor
> QWCCCHVC
> > rect.
> > 135406 CPF9999 40 ESC Function check.
> CPF1019
> QMHUNMSG
> > unmonitored by
> CHGDTAA
> > RA at statement
> 500, in
> > struction X'000F'.
> > Variables
> > Variable Type Length Value
> Valu
> >
> *...+....1....+....2....+ * .
> > &NUM *DEC 9 0 1
> >
> >
> > Do I need to put it into Hex or something? I am probably going to kick
> myself when I find out what I am doing wrong aren't I?
> >
> > Steve
> >
> >
> > -----Original Message-----
> > From: rpg400-l-bounces@xxxxxxxxxxxx
> > [mailto:rpg400-l-bounces@xxxxxxxxxxxx]On Behalf Of Jonathan Mason
> > Sent: 26 July 2005 13:48
> > To: 'RPG programming on the AS400 / iSeries'
> > Subject: RE: CHGDTAARA packed field
> >
> >
> > Hi Steve
> >
> > What error messages are you getting? How are you trying to change it?
> > Can you provide code samples?
> >
> > All the best
> >
> > Jonathan
> > www.astradyne-uk.com
> >
> >
> > -----Original Message-----
> > From: rpg400-l-bounces@xxxxxxxxxxxx
> > [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Raby, Steve (GE
> > Advanced Materials, consultant)
> > Sent: 26 July 2005 11:55
> > To: RPG programming on the AS400 / iSeries
> > Subject: CHGDTAARA packed field
> >
> > Hello All,
> >
> > I have a data area with a 9,0 packed field in that I am trying to
> > change, just a one off. I just keep getting error messages, how do I
> > change that?
> >
> > TIA
> >
> > Steve
> >
> >
> >
> > --
> > This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
> > list
> > To post a message email: RPG400-L@xxxxxxxxxxxx
> > To subscribe, unsubscribe, or change list options,
> > visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> > or email: RPG400-L-request@xxxxxxxxxxxx
> > Before posting, please take a moment to review the archives
> > at http://archive.midrange.com/rpg400-l.
> >
> >
> >
> > --
> > This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
> list
> > To post a message email: RPG400-L@xxxxxxxxxxxx
> > To subscribe, unsubscribe, or change list options,
> > visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> > or email: RPG400-L-request@xxxxxxxxxxxx
> > Before posting, please take a moment to review the archives
> > at http://archive.midrange.com/rpg400-l.
> >
> >
> > --
> > This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
> list
> > To post a message email: RPG400-L@xxxxxxxxxxxx
> > To subscribe, unsubscribe, or change list options,
> > visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> > or email: RPG400-L-request@xxxxxxxxxxxx
> > Before posting, please take a moment to review the archives
> > at http://archive.midrange.com/rpg400-l.
> >
> >
>
>
> --
> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
> list
> To post a message email: RPG400-L@xxxxxxxxxxxx
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> or email: RPG400-L-request@xxxxxxxxxxxx
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/rpg400-l.
>
>
>
> --
> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
> To post a message email: RPG400-L@xxxxxxxxxxxx
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> or email: RPG400-L-request@xxxxxxxxxxxx
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/rpg400-l.
>
>
> --
> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
> To post a message email: RPG400-L@xxxxxxxxxxxx
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
> or email: RPG400-L-request@xxxxxxxxxxxx
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/rpg400-l.
>
>
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.