2007 Dec 19 4:54 AM
Hi,
I am uploading one file with matnr,vkorg,vtweg through internal table(t_file)....and after calling GUI_UPLOAD,I have to check the internal table data with MVKE(matnr,vkorg,vtweg).
If the record exists then I have to delete the record and I have to send the record to as an errored record..
Can you please give me the logic????
Thanks in advance.
Reward will be given.
2007 Dec 19 5:00 AM
hi,
1 first fetch the records to a internal table(itab) GUI UPLOAD
2 loop through the internal table(itab) and check the condition u want.
3 if the conditon is true then move the record to another internal table(jtab) and delete the record from the present table(itab).
4 loop at jtab and display in output.
hi,
1 first fetch the records to a internal table(itab) GUI UPLOAD
2 loop through the internal table(itab) and check the condition u want.
3 if the conditon is true then move the record to another internal table(jtab) and delete the record from the present table(itab).
4 loop at jtab and display in output.
2007 Dec 19 5:00 AM
hi,
1 first fetch the records to a internal table(itab) GUI UPLOAD
2 loop through the internal table(itab) and check the condition u want.
3 if the conditon is true then move the record to another internal table(jtab) and delete the record from the present table(itab).
4 loop at jtab and display in output.
2007 Dec 19 5:09 AM
1. data into t_file gui_upload
2. select * from MVKE
into t_mvke.
3. loop at smaller table and sort and read t_mvke with key and use binary search for quick processing.
4. loop at t_file
read table t_mvke.
if sy-subrc = 0.
delete t_file.
endif.
endloop.
2007 Dec 19 5:58 AM
Data: t_index type sy-tabix.
Select matnr vkorg vtweg from mvke into it_mvke for all entries in t_file where matnr = t_file-matnr and vkorg in t_file-vkorg and vtweg in t_file-vtweg.
Loop at t_file.
t_index = sy-tabix.
Read table it_mvke with key matnr = t_file-matnr vkorg = t_file- vkorg vtweg = t_file-vtweg.
If sy-subrc = 0.
delete t_file index t_index.
Endif.
Endloop.
2007 Dec 19 6:34 AM
Hi
Check this code.I think this will help you.
loop at t_file into wa_file.
Read table t_mvke into wa_mvke with key matnr = wa_file-matnr
vkorg = wa_file-vkorg
vtweg = wa_file-vtweg.
if sy-subrc = '0'.
append wa_file into t_error.
else.
append wa_file into t_file2.
endif.
endloop.
Reward points if useful.
Regards
Shibin
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |