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

Former Member
0 Kudos

Hi,

I would like to sort the field lt_var. In that table I have entries like 100,50,200,22,5000.

Now my requirement is to sort these entries & the desired output should be 22,50,100,200,5000.

But after using sort statement in table LT_VAR for the field i have received the output as 100,22,200,50,5000.

Anybody will pls suggest me the logic for it??

5 REPLIES 5

Former Member
0 Kudos

Sort itab by vbeln ascending.

Former Member

Former Member
0 Kudos

Hi ,

check wht is the type of tht variable...?

Regards,

Former Member
0 Kudos

u have to use ascending.

Regards

Peram

Former Member
0 Kudos

neha,

I think the field that you are trying to sort is defined as type C.

If that is defined as type I, then sort would definitely work in a fashion that you require.

<b>Please reward with points if this is helpful.</b>

Kiran