2007 May 25 12:18 PM
Hi All,
I have Five fields in my internal table.
Say FIELD1, FIELD2, FIELD3, FIELD4, FIELD5.
I wan to display FIELD1 and FIELD3 in ascending order. Fields are Cobination of Text and Numerals.
Both should be displayed in ascending order. Is it possible? How can I achieve it.
Points Assured.
Regards,
Suresh
Hi All,
I have Five fields in my internal table.
Say FIELD1, FIELD2, FIELD3, FIELD4, FIELD5.
I wan to display FIELD1 and FIELD3 in ascending order. Fields are Cobination of Text and Numerals.
Both should be displayed in ascending order. Is it possible? How can I achieve it.
Points Assured.
Regards,
Suresh
2007 May 25 12:21 PM
hi,
use this
<b>sort itab ascending by field1 field3.</b>
With REgards,
S.BArani
Message was edited by:
S BHARANIDARAN
2007 May 25 12:21 PM
Hi
Use SORT ITAB BY field1 field3
but this sort is done based on the first character (first letter) of the field.
Reward points if useful
Regards
Anji
2007 May 25 12:21 PM
2007 May 25 12:34 PM
Hi,
I wan to display Field1 and Field3 in ascending order. Based on the Field1, Field3 may get suffled.
How to avoid this.?
Regards,
Suresh
2007 May 25 12:22 PM
Hi
try using Sort itab ascending by field1 field2
hope this works
Regards
Shiva
2007 May 25 12:22 PM
Its not possible in single SORT statement, you may need to copy into another table and do some manipulation to get the final one.
2007 May 25 12:27 PM
hi,
U CAN WRITE THE LIKE THIS.
DATA: BEGIN OF ITAB occurs 0,
MATNR TYPE MARA-MATNR,
ERSDA TYPE MARA-ERSDA,
ERNAM TYPE MARA-ERNAM,
VPSTA TYPE MARA-VPSTA,
PSTAT TYPE MARA-PSTAT,
END OF ITAB.
select * from mara into CORRESPONDING FIELDS OF TABLE itab.
sort itab DESCENDING by VPSTA MATNR.
loop at itab.
write: / itab.
endloop.
RGDS,
bharat.
| User | Count |
|---|---|
| 6 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |