1 .TYPES : BEGIN OF t_testcntrlstr,
A TYPE c,
B TYPE c,
C TYPE c,
END OF t_testcntrlstr.
DATA : i_testcntrlstr TYPE STANDARD TABLE OF t_testcntrlstr,
wa_testcntrlstr TYPE t_testcntrlstr.
LOOP AT i_testcntrlstr INTO wa_testcntrlstr.
AT FIRST.
WRITE : 'At First Output'.
WRITE : / wa_testcntrlstr-A ,
wa_testcntrlstr-B ,
wa_testcntrlstr-C .
ENDAT.
ENDLOOP.
Considering the table i_testcntrlstr contains the data as follows
A B C
1 1 2
1 2 2
2.REPORT zsaptechnical_test.
DATA: pos LIKE sy-index,
index(1).
DO 10 TIMES.
CHECK sy-index BETWEEN 2 AND 6.
ADD 1 TO pos.
MOVE sy-index TO index.
WRITE AT pos index.
ENDDO.
3. Which statement will sort the data of an internal table with fields FRUIT, QTY, and PRICE so that it appears as follows?
FRUIT QTY PRICE
Apples 12 22.50
Apples 9 18.25
Oranges 15 17.35
Bananas 20 10.20
Bananas 15 6.89
Bananas 5 2.75
A: SORT itab DESCENDING BY QTY PRICE.
B: SORT itab BY PRICE FRUIT.
C: SORT itab.
D: SORT itab BY PRICE DESCENDING.
4. The following program outputs what?
report zjgtest1
write: /1 'Ready_'.
PARAMETER: test.
INITIALIZATION.
write: /1 'Set_'.
START-OF-SELECTION.
write: /1 'GO!!'.
A: Set_ GO!! (each on its own line)
B: Set_ Ready_ GO!! (all on their own lines)
C: Ready_ GO!! (each on its own line)
D: Ready_ Set_ GO!! (all on their own lines)
5. Assuming an internal table contains 2000 entries, how many entries will it have after the following line of code is executed?
DELETE itab FROM 1500 TO 1700.
A: This is a syntax error.
B: 1801
C: 1800
D: 1799
6.What is output by the following code?
DATA: BEGIN OF itab OCCURS 0, letter type c, END OF itab.
itab-letter = 'A'. APPEND itab. itab-letter = 'B'. APPEND itab.
itab-letter = 'C'. APPEND itab. itab-letter = 'D'. APPEND itab.
LOOP AT itab.
SY-TABIX = 2.
WRITE itab-letter.
EXIT.
ENDLOOP.
A: A
B: A B C D
C: B
D: B C D
7.DATA: BEGIN OF itab OCCURS 10,
qty type I,
END OF itab.
DO 25 TIMES. itab-qty = sy-index. APPEND itab. ENDDO.
LOOP AT itab WHERE qty > 10.
WRITE: /1 itab-qty.
ENDLOOP.
This will result in:
A: Output of only those itab rows with a qty field less than 10
B: Output of the first 10 itab rows with a qty field greater than 10
C: A syntax error
D: None of the above
8.report zjgtest1
write: /1 'Ready_'.
INITIALIZATION.
write: /1 'Set_'.
START-OF-SELECTION.
write: /1 'GO!!'.
A: Set_ GO!! (each on its own line)
B: Set_ Ready_ GO!! (all on their own lines)
C: Ready_ GO!! (each on its own line)
D: Ready_ Set_ GO!! (all on their own lines)
9.report zjgtest1
write: /1 'Ready_'.
PARAMETER: test.
INITIALIZATION.
write: /1 'Set_'.
INITIALIZATION.
write: /1 'Set_'.
START-OF-SELECTION.
write: /1 'GO!!'.
A: Set_ GO!! (each on its own line)
B: Set_ Ready_ GO!! (all on their own lines)
C: Ready_ GO!! (each on its own line)
D: Ready_ Set_ GO!! (all on their own lines)
10.DATA: BEGIN OF itab OCCURS 0,
fval type i,
END OF itab.
itab-fval = 1.
APPEND itab.
itab-fval = 2.
DO 2 TIMES.
APPEND INITIAL LINE TO ITAB.
ENDDO.
DESCRIBE TABLE ITAB.
WRITE: / SY-TFILL.
11.REPORT ZTESTING1.
write: /1 'Ready_'.
END-OF-SELECTION.
WRITE:'HAI'.
START-OF-SELECTION.
WRITE:'BYE'.
INITIALIZATION.
WRITE:/ 'HELLO'.
what is the answer for 4th question...
ReplyDelete31. The following program outputs what?
report zjgtest1
write: /1 'Ready_'.
PARAMETER: test.
INITIALIZATION.
write: /1 'Set_'.
START-OF-SELECTION.
write: /1 'GO!!'.
A: Set_ GO!! (each on its own line)
B: Set_ Ready_ GO!! (all on their own lines)
C: Ready_ GO!! (each on its own line)
D: Ready_ Set_ GO!! (all on their own lines)