SAP CUD4_TABLE_DATA_GET Function Module for Read Content of Variant Table









CUD4_TABLE_DATA_GET is a standard cud4 table data get SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Read Content of Variant Table processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for cud4 table data get FM, simply by entering the name CUD4_TABLE_DATA_GET into the relevant SAP transaction such as SE37 or SE38.

Function Group: CUD4
Program Name: SAPLCUD4
Main Program:
Appliation area: C
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function CUD4_TABLE_DATA_GET pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'CUD4_TABLE_DATA_GET'"Read Content of Variant Table
EXPORTING
DATE = "Date

CHANGING
TABLE_HEADER = "
* END_OF_SEARCH = "
* NON_REGULAR_VALUES_USED = "

TABLES
* TABLE_CHARACTERISTICS = "
* TABLE_SELECTION_CRITERIA = "
* TABLE_ENTRIES_AUSP = "
* TABLE_LINES_CLOBJ = "

EXCEPTIONS
TABLE_EMPTY = 1 SEL_CRITERIA_NOT_FULLFILLED = 2 GENERATION_ERROR = 3
.




Customer Function user exits

Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.
EXIT_SAPLCUD4_001 Access Variant Table - Strategy for Finding Value Combinations

IMPORTING Parameters details for CUD4_TABLE_DATA_GET

DATE - Date

Data type: CABN-DATUV
Optional: No
Call by Reference: No ( called with pass by value option)

CHANGING Parameters details for CUD4_TABLE_DATA_GET

TABLE_HEADER -

Data type: CUVTAB
Optional: No
Call by Reference: No ( called with pass by value option)

END_OF_SEARCH -

Data type: C
Optional: Yes
Call by Reference: Yes

NON_REGULAR_VALUES_USED -

Data type: C
Optional: Yes
Call by Reference: Yes

TABLES Parameters details for CUD4_TABLE_DATA_GET

TABLE_CHARACTERISTICS -

Data type: API_CH_ATT
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLE_SELECTION_CRITERIA -

Data type: COMW
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLE_ENTRIES_AUSP -

Data type: AUSP
Optional: Yes
Call by Reference: No ( called with pass by value option)

TABLE_LINES_CLOBJ -

Data type: CLOBJ
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXCEPTIONS details

TABLE_EMPTY - Table without lines

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

SEL_CRITERIA_NOT_FULLFILLED -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

GENERATION_ERROR -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for CUD4_TABLE_DATA_GET Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than 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 newer method of declaring data variables on the fly. 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), which i why i have stuck to the origianl for this example.

DATA:
lv_date  TYPE CABN-DATUV, "   
lv_table_empty  TYPE CABN, "   
lv_table_header  TYPE CUVTAB, "   
lt_table_characteristics  TYPE STANDARD TABLE OF API_CH_ATT, "   
lv_end_of_search  TYPE C, "   
lt_table_selection_criteria  TYPE STANDARD TABLE OF COMW, "   
lv_sel_criteria_not_fullfilled  TYPE COMW, "   
lv_generation_error  TYPE COMW, "   
lt_table_entries_ausp  TYPE STANDARD TABLE OF AUSP, "   
lv_non_regular_values_used  TYPE C, "   
lt_table_lines_clobj  TYPE STANDARD TABLE OF CLOBJ. "   

  CALL FUNCTION 'CUD4_TABLE_DATA_GET'  "Read Content of Variant Table
    EXPORTING
         DATE = lv_date
    CHANGING
         TABLE_HEADER = lv_table_header
         END_OF_SEARCH = lv_end_of_search
         NON_REGULAR_VALUES_USED = lv_non_regular_values_used
    TABLES
         TABLE_CHARACTERISTICS = lt_table_characteristics
         TABLE_SELECTION_CRITERIA = lt_table_selection_criteria
         TABLE_ENTRIES_AUSP = lt_table_entries_ausp
         TABLE_LINES_CLOBJ = lt_table_lines_clobj
    EXCEPTIONS
        TABLE_EMPTY = 1
        SEL_CRITERIA_NOT_FULLFILLED = 2
        GENERATION_ERROR = 3
. " CUD4_TABLE_DATA_GET




ABAP code using 7.40 inline data declarations to call FM CUD4_TABLE_DATA_GET

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

"SELECT single DATUV FROM CABN INTO @DATA(ld_date).
 
 
 
 
 
 
 
 
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!