Monday, November 16, 2009

Extract the List of holidays between the 2 dates for the given factory/Holiday calendar:
REPORT zdp_holiday .
tables: tbkfk.
SELECT-OPTIONS:p_date FOR sy-datum.
DATA: lt_holidays type standard table of iscal_day.
parameters: p_facid like tbkfk-facid default 'NZ'.

CALL FUNCTION 'HOLIDAY_GET'
EXPORTING
HOLIDAY_CALENDAR = p_facid
* factory_calendar = p_facid
date_from = p_date-low
date_to = p_date-high
TABLES
holidays = lt_holidays
EXCEPTIONS
OTHERS = 5.

*---> Factory calendar Tcode: SCAL

No comments: