Application Development 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: 

Sorting Internal Table

Former Member
0 Kudos

Hi Experts,

While downloading into local file i want to sort my internal table, first two columns in ascending order, 3rd and 4th columns in decending and 5th and 6th columns in ascending order.

is it possible let me know

from

madhavi

7 REPLIES 7

Former Member
0 Kudos

before down loading u can sort internal table.

sort itab by ascending order, 3rd and 4th

sort itab decending and 5th and 6th .

Message was edited by:

Karthikeyan Pandurangan

0 Kudos

hai Karthikeyan Pandurangan

i know that Karthikeyan, but the thing is that i want to sort the internal table either ascending or decending, but not both, thats the problem

0 Kudos

Try with like this:

SORT ITAB BY FIELD1 ASCENDING
FIELD2 ASCENDING 
FIELD3 DESCENDING
FIELD4 DESCENDING
FIELD5 ASCENDING
FIELD6 ASCENDING

Regards,

Naimesh Patel

0 Kudos

Its not working Karthikeyan Pandurangan

0 Kudos

Hi, Madhavi t .

I think you should try Naimesh Patel's method.

Regards,

feng.

former_member386202
Active Contributor
0 Kudos

Hi,

Yes,

try like thisd

sort it_tab by matnr werks descending

Regards,

Prashant

Former Member
0 Kudos

u can sort independently all field finiallu move one internal table.