RS_VARIANT_CONTENTS_RFC 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 RS_VARIANT_CONTENTS_RFC into the relevant SAP transaction such as SE37 or SE80.
Associated Function Group:
SVAR_RFC
Released Date:
Not Released
Processing type: Remote-Enabled
CALL FUNCTION 'RS_VARIANT_CONTENTS_RFC' "
EXPORTING
report = " rsvar-report Report Name
variant = " rsvar-variant Variant Name
* move_or_write = 'W' " rsvar-flag1
* execute_direct = SPACE " rsvar-flag1
IMPORTING
return = " bapiret2 Return Code
TABLES
* l_params = " vanz
* l_params_nonv = " vanz
* l_selop = " vanz
* l_selop_nonv = " vanz
valutab = " rsparams
* valutabl = " rsparamsl
* objects = " vanz
* free_selections_desc = " rsdynbrepi
* free_selections_value = " rsseldyn
EXCEPTIONS
VARIANT_NON_EXISTENT = 1 "
VARIANT_OBSOLETE = 2 " Report does not exist
. " RS_VARIANT_CONTENTS_RFC
The ABAP code below is a full code listing to execute function module RS_VARIANT_CONTENTS_RFC 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).
| ld_return | TYPE BAPIRET2 , |
| it_l_params | TYPE STANDARD TABLE OF VANZ,"TABLES PARAM |
| wa_l_params | LIKE LINE OF it_l_params , |
| it_l_params_nonv | TYPE STANDARD TABLE OF VANZ,"TABLES PARAM |
| wa_l_params_nonv | LIKE LINE OF it_l_params_nonv , |
| it_l_selop | TYPE STANDARD TABLE OF VANZ,"TABLES PARAM |
| wa_l_selop | LIKE LINE OF it_l_selop , |
| it_l_selop_nonv | TYPE STANDARD TABLE OF VANZ,"TABLES PARAM |
| wa_l_selop_nonv | LIKE LINE OF it_l_selop_nonv , |
| it_valutab | TYPE STANDARD TABLE OF RSPARAMS,"TABLES PARAM |
| wa_valutab | LIKE LINE OF it_valutab , |
| it_valutabl | TYPE STANDARD TABLE OF RSPARAMSL,"TABLES PARAM |
| wa_valutabl | LIKE LINE OF it_valutabl , |
| it_objects | TYPE STANDARD TABLE OF VANZ,"TABLES PARAM |
| wa_objects | LIKE LINE OF it_objects , |
| it_free_selections_desc | TYPE STANDARD TABLE OF RSDYNBREPI,"TABLES PARAM |
| wa_free_selections_desc | LIKE LINE OF it_free_selections_desc , |
| it_free_selections_value | TYPE STANDARD TABLE OF RSSELDYN,"TABLES PARAM |
| wa_free_selections_value | LIKE LINE OF it_free_selections_value . |
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_return | TYPE BAPIRET2 , |
| ld_report | TYPE RSVAR-REPORT , |
| it_l_params | TYPE STANDARD TABLE OF VANZ , |
| wa_l_params | LIKE LINE OF it_l_params, |
| ld_variant | TYPE RSVAR-VARIANT , |
| it_l_params_nonv | TYPE STANDARD TABLE OF VANZ , |
| wa_l_params_nonv | LIKE LINE OF it_l_params_nonv, |
| ld_move_or_write | TYPE RSVAR-FLAG1 , |
| it_l_selop | TYPE STANDARD TABLE OF VANZ , |
| wa_l_selop | LIKE LINE OF it_l_selop, |
| ld_execute_direct | TYPE RSVAR-FLAG1 , |
| it_l_selop_nonv | TYPE STANDARD TABLE OF VANZ , |
| wa_l_selop_nonv | LIKE LINE OF it_l_selop_nonv, |
| it_valutab | TYPE STANDARD TABLE OF RSPARAMS , |
| wa_valutab | LIKE LINE OF it_valutab, |
| it_valutabl | TYPE STANDARD TABLE OF RSPARAMSL , |
| wa_valutabl | LIKE LINE OF it_valutabl, |
| it_objects | TYPE STANDARD TABLE OF VANZ , |
| wa_objects | LIKE LINE OF it_objects, |
| it_free_selections_desc | TYPE STANDARD TABLE OF RSDYNBREPI , |
| wa_free_selections_desc | LIKE LINE OF it_free_selections_desc, |
| it_free_selections_value | TYPE STANDARD TABLE OF RSSELDYN , |
| wa_free_selections_value | LIKE LINE OF it_free_selections_value. |
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 RS_VARIANT_CONTENTS_RFC or its description.