I think my WHERE condition is not satisfied because I have not specified BELNR in my WHERE condition. I tried specifying BELNR in WHERE condition as below. SELECT belnr gjahr ebeln INTO TABLE WT_RSEG FROM RSEG FOR ALL ENTRIES IN ITAB WHERE belnr eq itab-awkey "I have also tried...
SAP Managed Tags: ABAP Development Not a good idea to delete records from a table that you are looping through. SY-TABIX would be hard to interpret. Having said that, we quite often delete the particular line that we are on. Rob Edited by: Rob Burbank on Apr 6, 2009 5:32 PM ...
SAP Managed Tags: ABAP Development Hi ! Here are things you could do: 1. You can use nested loops with the WHERE statement on the inner loop. But this can be slow. This will look like this loop at i_tab1 into wa1 loop at i_tab2 into wa2 where cond1 = wa1-cond1... ( move...
The information required is the records of table A which satisfy the "condition" in each row of table B. Which would be the best way to approach it keeping the performance issue in mind ? In other words how to build a dynamic where clause to loop through Table A with the info available...
In that case then you should consider another WHERE condition also otherwise the same PO will be read. Why are you clearing WA_COLLECT1 within the loop? LOOP at wa_collect1. MOVE-CORRESPONDING WA_COLLECT1 TO WA4. READ TABLE IT2 INTO wa2 WITH KEY ebeln = wa2-ebeln. IF SY-SUBRC = 0...
SAP Managed Tags: ABAP Development Hi, You can do that, but with little modification Don't use DELETE statement in LOOP and ENDLOOP statement, instead set a flag if the condition is met. Note:- If we use DELETEstatement in LOOP, every time the statement is executed, it has to r...