2-What is the difference between At New and On change Of
inside a loop??I want inside a loop difference not basic
difference??
Answer Posted / bhuvanya
Q. What is the difference between 'At New / End At' and 'On Change Of / EndOn'?
1. 'On Change Of' can be used in any loop construct, not just 'Loop At'.
2. A Single 'On Change Of' can be triggered by a change within one or more fields named after of and separated by OR.
3. When used within a loop, a change in a field to the left of the control level does not trigger a control break.
4. When used within a loop, fields to the right still contain their original values; they are not changed to contain zero or asterisks.
5. You can use 'else' statement between 'On Change OF' and 'End On'. You can also use ELSEIF statements in conjunction with special implementation of ON, but should always try to avoid this because they may not be supported in future.
6. You can use it with 'Loop At' IT WHERE clause……
7. You can use 'SUM' with 'On Change Of'. It sums all numeric fields except the one(s) named after Of.
8. Another difference is while using 'at new' in case if you code any write statements between 'at new' and 'end at' the value for the numeric fields will be returned as 0 and that of no numeric fields will be returned as *(asterisk). But in on change of the original values will be returned.
NOTE: Use the 'At First' and 'At Last' statement to perform during the first or last pass of internal table. These statements can only be used within 'LOOP AT'; they cannot be used within select.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are the different types of sapscript symbols?
How to call a subroutine in sapscript?
What is the difference between call transaction method and the session method? : abap bdc
Update function modules are classified as either v1 or v2. Which type of update is performed first and in what mode (asynchronously, synchronously or locally) can each type be processed in?
What are the differences between macro and subroutine?
When was the sap abap being created?
what is the exact code that shoud be implimented in sap note
What is a table attribute? : abap data dictionary
What is meant by write lock? : sap abap data dictionary
i have cleared my technical round and manager round in cts but they told me u will get a call with in couple of days now i dont know about my status
What are the functional areas, user groups? How does abap query work in relation to these?
Explain buffering concept usage?
Explain the sequences of event block?
I am getting the (first) page number and the remaining records displayed in another list in another page BUT the PAGE Number is not displayed? What is the code/solution?
What are the different types of laws. What are they?