2008 Feb 28 6:43 AM
one can set the value of sy-tabix dynamically(in a program) or not?
one can set the value of sy-tabix dynamically(in a program) or not?
2008 Feb 28 6:46 AM
YES IT IS POSSIBLE TO DO IT.
example
read table p_it_history with key ebeln = wa_final-ebeln
ebelp = wa_final-ebelp
binary search transporting no fields.
loop at p_it_history into wa_history from sy-tabix
where ebeln = wa_final-ebeln
and ebelp = wa_final-ebelp.
wa_final-bewtp = wa_history-bewtp.
wa_final-bwart = wa_history-bwart.
wa_final-belnr = wa_history-belnr.
wa_final-buzei = wa_history-buzei.
wa_final-budat = wa_history-budat.
wa_final-bpmng = wa_history-bpmng.
wa_final-wrbtr = wa_history-wrbtr.
wa_final-shkzg = wa_history-shkzg.
wa_final-vgabe = wa_history-vgabe.
append wa_final to p_it_final.
plz reawrd if useful
keep rockin
vivek
2008 Feb 28 6:53 AM
but in the program code given by you,sy-tabix will adjust to a system value. according to me,for example in your program,only one record will be read and that should be the very first record.is not it?
if,say i have set sy-tabix = 5 just above the loop statement ,then is it that 5th record will be stored in the work area mentioned????
plz clarify.
2008 Feb 28 6:57 AM
but in the program code given by you,sy-tabix will adjust to a system value. according to me,for example in your program,only one record will be read and that should be the very first record.is not it?
if,say i have set sy-tabix = 5 just above the loop statement ,then is it that 5th record will be stored in the work area mentioned????
plz clarify.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |