‎2008 Jul 21 8:36 AM
hi frnds,
My report shows only last 2 billing schedule of line item of contract no. 10117418,
BillSt (Billing status) of which is u201CA- Not yet processedu201D.
but it should include all billing schedules which has BillSt= A,B & C (u201CFPLT- FKSAF = A,B&Cu201D)
In the existing report the code is something like
DATA: BEGIN OF I_BILLING OCCURS 0.
INCLUDE STRUCTURE FPLTVB.
DATA: END OF I_BILLING.
where they have used structure and code as
IF I_BILLING-FKSAF EQ 'A'----
>> status only for A.
AND I_BILLING-FKDAT EQ T_BILL_DATE.
V_WAERK = I_BILLING-WAERS.
SELECT SINGLE * FROM TCURX
WHERE CURRKEY = V_WAERK .
IF SY-SUBRC = 0.
I_BILLING-FAKWR = I_BILLING-FAKWR * 100.
ENDIF.
-
>> my requirement is to get all the contract no for which bill status is A B and c.
HOW TO code this.
‎2008 Jul 21 8:39 AM
hi,
IF I_BILLING-FKSAF EQ 'A' AND I_BILLING-FKSAF EQ 'B' AND I_BILLING-FKSAF EQ 'C' -
>> status only for A,B,C.
AND I_BILLING-FKDAT EQ T_BILL_DATE.
RGDS.,
SUBASH
‎2008 Jul 21 9:00 AM
Hi
Try the following and check.
IF I_BILLING-FKSAF CO 'ABC' .
.....You code goes here.....
ENDIF.
Hope this would help you.
Murthy
‎2008 Jul 21 9:01 AM
Hi Daniel,
Your logic shud be:
IF ( I_BILLING-FKSAF EQ 'A' OR
I_BILLING-FKSAF EQ 'B' OR
I_BILLING-FKSAF EQ 'C' )
AND I_BILLING-FKDAT EQ T_BILL_DATE.
Your code
ENDIF.
Regards,
Nadim
‎2008 Jul 21 9:03 AM
Hi,
If A,B and C are the only possible values for FPLT- FKSAF then you can remove the condition for FKSAF field and write the select query as follows:
I_BILLING-FKDAT EQ T_BILL_DATE.
V_WAERK = I_BILLING-WAERS.
SELECT SINGLE * FROM TCURX
WHERE CURRKEY = V_WAERK .
IF SY-SUBRC = 0.
I_BILLING-FAKWR = I_BILLING-FAKWR * 100.
ENDIF.
If it contains values other than these three then write teh select query as follows:
IF I_BILLING-FKSAF EQ 'A' or
I_BILLING-FKSAF EQ 'B' or
I_BILLING-FKSAF EQ 'C' -
>> status only for A,B & C.
AND I_BILLING-FKDAT EQ T_BILL_DATE.
V_WAERK = I_BILLING-WAERS.
SELECT SINGLE * FROM TCURX
WHERE CURRKEY = V_WAERK .
IF SY-SUBRC = 0.
I_BILLING-FAKWR = I_BILLING-FAKWR * 100.
ENDIF.
Hope this will help.
Regards,
Swarna Munukoti.