Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Process internal table

former_member384574
Active Participant
0 Likes
377

Hi experts,

I need help, I don't know how can I do that, I've an internal table like below..

date status hour

06/08/10 01 9:00

06/08/10 03 9:15

06/08/10 01 9:20

06/08/10 02 9:50

07/08/10 01 12:00

07/08/10 02 12:00

08/08/10 01 12:00

From that internal table I need these which the date is unique and has the maxim hour, for that table I will need that entries:

06/08/10 02 9:50

07/08/10 02 12:00

08/08/10 01 12:00

Can anybody help me? I don't know how can I do that

Thanks in advanced,

Regards,

Rebeca

2 REPLIES 2
Read only

Former Member
0 Likes
346

Hi,

Please sort and then use delete adjacent duplicates.

Sort itab by date hour descending.

delete adjacent duplicates from itab comparing date.

Regards,

Srini.

Read only

guillaume-hrc
Active Contributor
0 Likes
346

Hi,

Use SORT on the date and hour. (It is simpler if the date and hour are in 1st and 2nd position in your table)

Then the LOOP AT ... AT NEW date would allow you to fill a new table with entries that you want.

Best regards,

Guillaume