LUEBBKEVIN
Programmer
I don't remember if there is a conversion method in RPG or not (the mind is going fast)
I have a field in a file defined
END DATE IADEND P 8 0
data formatted as ccyymmdd
In my program I load this field to a work field that is defined as:
D @H_ENDDATE S Like(ENDDATE)
I also created another work field for the duration:
D @H_DURATION S Like(ENDDATE)
In the program the @H_ENDDATE field is loaded with
the value in the data file END DATE
The @H_ENDDATE is copied to @H_DURATION
EVAL @H_DURATION = H_ENDDATE
The ADDDUR function is run over the @H_DURATION
ADDDUR 1:*DAYS @H_DURATION
on the compile I get
*RNF7261 30 134919 The Result-Field operand @H_DURATION is not valid for the
specified operation.
can't find much on the function to know what format restrictions exist.
I have a field in a file defined
END DATE IADEND P 8 0
data formatted as ccyymmdd
In my program I load this field to a work field that is defined as:
D @H_ENDDATE S Like(ENDDATE)
I also created another work field for the duration:
D @H_DURATION S Like(ENDDATE)
In the program the @H_ENDDATE field is loaded with
the value in the data file END DATE
The @H_ENDDATE is copied to @H_DURATION
EVAL @H_DURATION = H_ENDDATE
The ADDDUR function is run over the @H_DURATION
ADDDUR 1:*DAYS @H_DURATION
on the compile I get
*RNF7261 30 134919 The Result-Field operand @H_DURATION is not valid for the
specified operation.
can't find much on the function to know what format restrictions exist.