03-15-2008 7:38 PM
Hi,
I have to filter a database table based on the settlement period( IDENT3 ) and the field available is of date field. Can anyone give me a function module by which can calculate the starting date and ending date by providing the settlement period ( eg. AM- Monthly, AQ- Quarterly, AJ- Annually, etc ) and date.
Thanx in advance.
Regards,
Sumanth.
03-17-2008 3:11 PM
Hi Sumanth,
Please use the function module 'DATE_CONVERT_TO_FACTORYDATE' to get the start date and end date for the particular factory calender.
For end date:
CORRECT_OPTION +
DATE sy-datum
FACTORY_CALENDAR_ID Aq(quaterly)
For start date:
CORRECT_OPTION -
DATE sy-datum
FACTORY_CALENDAR_ID Aq(quaterly)
According to sy-datum, it will calculate the Extreme interval .
Thanx,
Zenthil.
03-17-2008 3:11 PM
Hi Sumanth,
Please use the function module 'DATE_CONVERT_TO_FACTORYDATE' to get the start date and end date for the particular factory calender.
For end date:
CORRECT_OPTION +
DATE sy-datum
FACTORY_CALENDAR_ID Aq(quaterly)
For start date:
CORRECT_OPTION -
DATE sy-datum
FACTORY_CALENDAR_ID Aq(quaterly)
According to sy-datum, it will calculate the Extreme interval .
Thanx,
Zenthil.