How will you display top 5 records form an internal table ?
Answers were Sorted based on User's Feedback
Answer / narasareddy
write a simple syntax:
loop at it_tab1 INTO wa_tab from 1 to 5.
ENDLOOP.
Is This Answer Correct ? | 23 Yes | 1 No |
Answer / balaji.p
hi,i think,
1.u have declare another internal table (it_tab2).
2.then u use (append multiple lines of )
3.then write syntax ,
APPEND LINES OF IT_TAB1 FROM N1 TO N2 TO IT_TAB2.
4. THEN write loop at it_tab2 into wa.
write:/--------------------------
endloop.
OR
1.USE READ STATEMENT.
2.IT HAS 2 TYPES A.BY USING INDEX
B.BY USING KEY
3.USE READ STATEMENT USING ,B(BY USING KEY),i MEAN
SYNTAX:READ<INT_TAB>INTO WA WITH KEY KUNNR = '1',
KUNNR = '2',
KUNNR = '3',
KUNNR = '4',
KUNNR = '5'.
4.THEN write loop at it_tab into wa.
write:/--------------------------
endloop
Is This Answer Correct ? | 11 Yes | 3 No |
Answer / rakesh kaushik
Loop at < workarea_name> into <internaltable_name> from 1 to 5 .
Means
loop at itab into it_main into from 1 to 5 .
Is This Answer Correct ? | 5 Yes | 3 No |
Answer / samir
SORT ITAB.
DELETE ITAB WHERE INDEX > 5.
tHEN DISPLAY THE INTERNAL TABLE.
Is This Answer Correct ? | 4 Yes | 4 No |
i think
do 5 times.
read itab with key xxx.
ktab-xxxx = itab-xxxx.
append ktab.
enddo.
it myt work
Is This Answer Correct ? | 2 Yes | 5 No |
What is the use of protect & endprotect?
How to print page numbers in a script through SE38 Program ?
How to change the package of a SAP Script ?
Can i Have Some Realtime Examples on Scripts ?
How would you call a subroutine in sap script?
What is the default event that triggers when u run a report?
/: ADDRESS PARAGRAPH AS /: NAME &LFA1-NAME1& . . /: COUNTRY &LFA1-LAND1& THIS CODE IS NOT GENERATING ANY ADDRESS ON THE OUTPUT FORM. IF I NEED TO PRINT THE ADDRESS THEN,WAT CODE I NEED TO FOLLOW?EVEN I READ THE DATA THRU THE SELECT STATEMENT IN MY OWN DRIVER PROGRAM!
How to add extra functionality to a standard print program without touching the print program ?
How do u upload the images in script?
I receive 5 orders from customer. Irrespective of Value or quantity, first 3 orders get discount. From 4th order onwards no discount. How to do this?
how we can debug in sap scipt
Explain the windows in layout set.