on 01-10-2008 7:53 AM
We have created a ztable by name zcpdcurr,zcpdhtry,....
I have fetching data from two tables zcpdcurr and vbep.. while fetching data i need to check the 'order qty(wmeng)' in vbep and 'cpd_qty' in zcpdcurr.
*If less then we need to make the cpd_qty in zcpdcurr equal with order_qty in vbep*
*If greater than we need to make the cpd_qty equal with order_qty in vbep*
so anyone can help me detailed code,.....
Edited by: murari sampath kumar on Jan 10, 2008 11:34 AM
Hi Murari,
There is no field by name cpd_qty present in the vbep table.
Can you please elaborate the issue clearly.
Thanks,
Kashyap Ivaturi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Murari,
First you need to compare the wmeng field in the vbep table with the cpd_qty field in the zcpdcurr table to know which one is greater.Then you can make the values equal.
For that you can use the following code.
TABLES : vbep , zcpdcurr.
DATA : BEGIN OF ITAB OCCURS 10,
WMENG LIKE VBEP-WMENG,
CPD_QTY LIKE ZCPDCURR-CPD_QTY,
END OF ITAB.
select single awmeng bcpd_qty into ITAB from vbep as a JOIN zcpdcurrr as b .
loop at itab.
IF itab-wmeng LT itab-cpd_qty OR itab-wmeng GT itab-cpd_qty .
zcdcurr-cpd_qty = itab-wmeng.
endif.
endloop.
Reward if helpfull.
Thanks,
Kashyap Ivaturi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
103 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.