suma Beginner
Joined: 23 Jan 2006 Posts: 65 Topics: 29
|
Posted: Tue Feb 28, 2006 2:57 am Post subject: highest number |
|
|
Hi all,
I have to move the occurs group
from
05 Gp1 OCCURS 3 TIMES.
10 d PIC X(02).
10 e PIC X(06).
to
05 gp2 OCCURS 3 TIMES.
10 d PIC X(02).
10 e PIC X(06).
the values e of gp1(1) > e of gp1(2)> e of gp1(3), in this case highest value gp1(1) will be moved to gp2(1), 2 to 2 ....
but sometimes they are all like this e of gp1(1) = e of gp1(2) = e of gp1(3), at this point i have to check which is the highest among d of gp1 and move highest value to lowest value to gp2.
Please let me know the logic to find the highest of numbers:
regds.
suma |
|