SAP Function Modules

ISP_SHOW_IHKOHY_TREE SAP Function module - IS-M: Display Content Component Hierarchy in Tree Format







ISP_SHOW_IHKOHY_TREE 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 ISP_SHOW_IHKOHY_TREE into the relevant SAP transaction such as SE37 or SE80.

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


Pattern for FM ISP_SHOW_IHKOHY_TREE - ISP SHOW IHKOHY TREE





CALL FUNCTION 'ISP_SHOW_IHKOHY_TREE' "IS-M: Display Content Component Hierarchy in Tree Format
* EXPORTING
*   xexpand = SPACE             " sy-batch
*   xpick_multiple =            " sy-batch
*   xpick_leave = CON_ANGEKREUZT  " sy-batch
*   gueltig_von =               " sy-datum
*   gueltig_bis =               " sy-datum
*   obj_art =                   " jjtobjin-obj_art
*   beleinh = SPACE             " jjtbe-beleinh
*   iko_hietyp =                " jjtikohy-iko_hietyp
  TABLES
    inhkohy =                   " jjtikohy      Content Component Hierarchy
*   chosen_nodes =              " jjtikohy
  EXCEPTIONS
    TREE_FAILURE = 1            "
    .  "  ISP_SHOW_IHKOHY_TREE

ABAP code example for Function Module ISP_SHOW_IHKOHY_TREE





The ABAP code below is a full code listing to execute function module ISP_SHOW_IHKOHY_TREE 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:
it_inhkohy  TYPE STANDARD TABLE OF JJTIKOHY,"TABLES PARAM
wa_inhkohy  LIKE LINE OF it_inhkohy ,
it_chosen_nodes  TYPE STANDARD TABLE OF JJTIKOHY,"TABLES PARAM
wa_chosen_nodes  LIKE LINE OF it_chosen_nodes .

DATA(ld_xexpand) = 'some text here'.
DATA(ld_xpick_multiple) = 'some text here'.
DATA(ld_xpick_leave) = 'some text here'.
DATA(ld_gueltig_von) = '20210129'.
DATA(ld_gueltig_bis) = '20210129'.

SELECT single OBJ_ART
FROM JJTOBJIN
INTO @DATA(ld_obj_art).


SELECT single BELEINH
FROM JJTBE
INTO @DATA(ld_beleinh).


SELECT single IKO_HIETYP
FROM JJTIKOHY
INTO @DATA(ld_iko_hietyp).


"populate fields of struture and append to itab
append wa_inhkohy to it_inhkohy.

"populate fields of struture and append to itab
append wa_chosen_nodes to it_chosen_nodes. . CALL FUNCTION 'ISP_SHOW_IHKOHY_TREE' * EXPORTING * xexpand = ld_xexpand * xpick_multiple = ld_xpick_multiple * xpick_leave = ld_xpick_leave * gueltig_von = ld_gueltig_von * gueltig_bis = ld_gueltig_bis * obj_art = ld_obj_art * beleinh = ld_beleinh * iko_hietyp = ld_iko_hietyp TABLES inhkohy = it_inhkohy * chosen_nodes = it_chosen_nodes EXCEPTIONS TREE_FAILURE = 1 . " ISP_SHOW_IHKOHY_TREE
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here 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_xexpand  TYPE SY-BATCH ,
it_inhkohy  TYPE STANDARD TABLE OF JJTIKOHY ,
wa_inhkohy  LIKE LINE OF it_inhkohy,
ld_xpick_multiple  TYPE SY-BATCH ,
it_chosen_nodes  TYPE STANDARD TABLE OF JJTIKOHY ,
wa_chosen_nodes  LIKE LINE OF it_chosen_nodes,
ld_xpick_leave  TYPE SY-BATCH ,
ld_gueltig_von  TYPE SY-DATUM ,
ld_gueltig_bis  TYPE SY-DATUM ,
ld_obj_art  TYPE JJTOBJIN-OBJ_ART ,
ld_beleinh  TYPE JJTBE-BELEINH ,
ld_iko_hietyp  TYPE JJTIKOHY-IKO_HIETYP .

ld_xexpand = 'some text here'.

"populate fields of struture and append to itab
append wa_inhkohy to it_inhkohy.
ld_xpick_multiple = 'some text here'.

"populate fields of struture and append to itab
append wa_chosen_nodes to it_chosen_nodes.
ld_xpick_leave = 'some text here'.
ld_gueltig_von = '20210129'.
ld_gueltig_bis = '20210129'.

SELECT single OBJ_ART
FROM JJTOBJIN
INTO ld_obj_art.


SELECT single BELEINH
FROM JJTBE
INTO ld_beleinh.


SELECT single IKO_HIETYP
FROM JJTIKOHY
INTO ld_iko_hietyp.

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 ISP_SHOW_IHKOHY_TREE or its description.