2008 Dec 15 12:33 PM
Hi Gurus,
I am trying to convert calenderday to fiscal day (i.e. day remains the same from calender day, Month and year are populated from function module.
I am getting error message that syst date : 00.00.0000 is not expected.
data:
i_tab(2) type c value 'V3',
i_tab1 like COMM_STRUCTURE-fiscper,
i_tab2 like COMM_STRUCTURE-fiscyear,
i_tab3(2) type c,
i_tab4 like COMM_STRUCTURE-dateto,
i_tab5(2) type c.
CALL FUNCTION 'UMC_CALDAY_TO_FISCPER'
EXPORTING
I_PERIV = i_tab
I_CALDAY = COMM_STRUCTURE-DATEto
IMPORTING
E_FISCPER = i_tab1.
break-point.
i_tab4 = COMM_STRUCTURE-dateto.
i_tab5 = i_tab4+6(2).
i_tab2 = i_tab1+0(4).
i_tab3 = i_tab1+5(2).
if i_tab5 >= 29.
i_tab5 = 28.
endif.
concatenate i_tab2 i_tab3 i_tab5 into RESULT.
any help greatly appreciated. Thanks.
Regards,
Reddy.
Hi Gurus,
I am trying to convert calenderday to fiscal day (i.e. day remains the same from calender day, Month and year are populated from function module.
I am getting error message that syst date : 00.00.0000 is not expected.
data:
i_tab(2) type c value 'V3',
i_tab1 like COMM_STRUCTURE-fiscper,
i_tab2 like COMM_STRUCTURE-fiscyear,
i_tab3(2) type c,
i_tab4 like COMM_STRUCTURE-dateto,
i_tab5(2) type c.
CALL FUNCTION 'UMC_CALDAY_TO_FISCPER'
EXPORTING
I_PERIV = i_tab
I_CALDAY = COMM_STRUCTURE-DATEto
IMPORTING
E_FISCPER = i_tab1.
break-point.
i_tab4 = COMM_STRUCTURE-dateto.
i_tab5 = i_tab4+6(2).
i_tab2 = i_tab1+0(4).
i_tab3 = i_tab1+5(2).
if i_tab5 >= 29.
i_tab5 = 28.
endif.
concatenate i_tab2 i_tab3 i_tab5 into RESULT.
any help greatly appreciated. Thanks.
Regards,
Reddy.
2008 Dec 15 12:51 PM
HI,
report zrich_0001 .
data: posting_period like t009b-poper,
posting_year like bkpf-gjahr,
datum type sy-datum value '20060202'.
call function 'FI_PERIOD_DETERMINE'
exporting
i_budat = datum
I_PERIV = 'YT' "<-- Fiscal Year Variant
importing
e_gjahr = posting_year
e_poper = posting_period.
write:/ posting_period, posting_year.
2008 Dec 15 12:59 PM
Hi Avinash,
Thanks for reply. i want to concantenate the date to fiscal period and year. When i do the concatenation. I am getting error syst date :00.00.0000 not expected.
Any help grealty appreciated.
Regards,
Reddy.
2008 Dec 15 1:17 PM
HI,
Try these FM FIRST_DAY_IN_PERIOD_GET,LAST_DAY_IN_PERIOD_GET
2008 Dec 15 3:15 PM
Hi Avinash,
If input calender day is 00.00.0000, then i want result to be space otherwise calculate fiscal day. This is why i am getting the syst date : 00.00.0000 is not expected error.
Cheers,
Reddy.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |