SAP Function Modules

CATS_READ_SPLIT SAP Function module







CATS_READ_SPLIT is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name CATS_READ_SPLIT into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: CATL2
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM CATS_READ_SPLIT - CATS READ SPLIT





CALL FUNCTION 'CATS_READ_SPLIT' "
  EXPORTING
    i_catsfields =              " catsfields
    i_eq_vertl =                " tc29-vertl
    i_unit_of_hour =            " t006-msehi
    i_unit_of_day =             " t006-msehi
    i_werks =                   " t001w-werks
*   i_ext_call = SPACE          " c
  IMPORTING
    e_tcats_calendar =          " tcats-calendar
  TABLES
    t_icatsw =                  " catsw
    t_blocked_days =            "
  CHANGING
    c_ucatsd =                  " catsd
    c_tcats =                   " tcats
    c_workday_w =               " sy-marky
    .  "  CATS_READ_SPLIT

ABAP code example for Function Module CATS_READ_SPLIT





The ABAP code below is a full code listing to execute function module CATS_READ_SPLIT including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
ld_e_tcats_calendar  TYPE TCATS-CALENDAR ,
it_t_icatsw  TYPE STANDARD TABLE OF CATSW,"TABLES PARAM
wa_t_icatsw  LIKE LINE OF it_t_icatsw ,
it_t_blocked_days  TYPE STANDARD TABLE OF STRING,"TABLES PARAM
wa_t_blocked_days  LIKE LINE OF it_t_blocked_days .

DATA(ld_c_ucatsd) = 'Check type of data required'.
DATA(ld_c_tcats) = 'Check type of data required'.
DATA(ld_c_workday_w) = 'some text here'.
DATA(ld_i_catsfields) = 'some text here'.

SELECT single VERTL
FROM TC29
INTO @DATA(ld_i_eq_vertl).


SELECT single MSEHI
FROM T006
INTO @DATA(ld_i_unit_of_hour).


SELECT single MSEHI
FROM T006
INTO @DATA(ld_i_unit_of_day).


SELECT single WERKS
FROM T001W
INTO @DATA(ld_i_werks).

DATA(ld_i_ext_call) = 'some text here'.

"populate fields of struture and append to itab
append wa_t_icatsw to it_t_icatsw.

"populate fields of struture and append to itab
append wa_t_blocked_days to it_t_blocked_days. . CALL FUNCTION 'CATS_READ_SPLIT' EXPORTING i_catsfields = ld_i_catsfields i_eq_vertl = ld_i_eq_vertl i_unit_of_hour = ld_i_unit_of_hour i_unit_of_day = ld_i_unit_of_day i_werks = ld_i_werks * i_ext_call = ld_i_ext_call IMPORTING e_tcats_calendar = ld_e_tcats_calendar TABLES t_icatsw = it_t_icatsw t_blocked_days = it_t_blocked_days CHANGING c_ucatsd = ld_c_ucatsd c_tcats = ld_c_tcats c_workday_w = ld_c_workday_w . " CATS_READ_SPLIT
IF SY-SUBRC EQ 0. "All OK ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_c_ucatsd  TYPE CATSD ,
ld_e_tcats_calendar  TYPE TCATS-CALENDAR ,
ld_i_catsfields  TYPE CATSFIELDS ,
it_t_icatsw  TYPE STANDARD TABLE OF CATSW ,
wa_t_icatsw  LIKE LINE OF it_t_icatsw,
ld_c_tcats  TYPE TCATS ,
ld_i_eq_vertl  TYPE TC29-VERTL ,
it_t_blocked_days  TYPE STANDARD TABLE OF STRING ,
wa_t_blocked_days  LIKE LINE OF it_t_blocked_days,
ld_c_workday_w  TYPE SY-MARKY ,
ld_i_unit_of_hour  TYPE T006-MSEHI ,
ld_i_unit_of_day  TYPE T006-MSEHI ,
ld_i_werks  TYPE T001W-WERKS ,
ld_i_ext_call  TYPE C .

ld_c_ucatsd = 'some text here'.
ld_i_catsfields = 'some text here'.

"populate fields of struture and append to itab
append wa_t_icatsw to it_t_icatsw.
ld_c_tcats = 'some text here'.

SELECT single VERTL
FROM TC29
INTO ld_i_eq_vertl.


"populate fields of struture and append to itab
append wa_t_blocked_days to it_t_blocked_days.
ld_c_workday_w = 'some text here'.

SELECT single MSEHI
FROM T006
INTO ld_i_unit_of_hour.


SELECT single MSEHI
FROM T006
INTO ld_i_unit_of_day.


SELECT single WERKS
FROM T001W
INTO ld_i_werks.

ld_i_ext_call = 'some text here'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name CATS_READ_SPLIT or its description.