‎2008 Jun 10 2:13 PM
Hi,
can anybody tell me how to do logic by combing these detils
KONV-KBETR if KONV-KSCHL=PSPR
Linked by VBAK-KNUMV=KONV-KNUMV
and
VBAP-VBELN=VBAK-VBELN
Display profit margin only if KNA1- ktokd = BAIC.
knov-kbetr is profit margin
Please help me in this regard
Thanks,
lavanya
‎2008 Jun 10 2:26 PM
Get all the Customers KNA1-KUNNR from KNA1 table for the account group KTOKD = BAIc.
For all these customers find the Sales orders (VBELN)and the Condition records (KNUMV) fromthe VBAK table.
Now retrieve the profit margin(KBETR) from KONV for the above condition records(VBAK-KNUMV). While retrieving put the condition KONV-KSCHL = 'PSPR' also in the WHERE clause of select.
\[removed by moderator\]
Regards,
Kiran Bobbala
Edited by: Jan Stallkamp on Jun 10, 2008 3:38 PM
‎2008 Jun 11 4:45 AM
Hi kiran,
plz tell me why i am getting this error
@8O@ "END" must be a flat structure. You cannot use internal tables, strings, references, or structures as components .
select kunnr from kna1 into table it_kna1 where ktokd = 'baic'.
select vbeln from vbap into table it_vbap for all entries in it_vbak
where vbeln = vbak-vbeln.
select kunnr vbeln knumv from vbak into table it_vbak
for all entries in it_kna1 where kunnr = kna1-kunnr.
select kbetr knumv kschl from table konv into it_konv
for all the entries in it_vbak where knumv = vbak-knumv
and koschl = 'pspr'.
Is my coding correct plz help me.