SAP RKZ_OPEN_SEQ_FILE Function Module for Open seq. files /output ,input









RKZ_OPEN_SEQ_FILE is a standard rkz open seq file SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Open seq. files /output ,input 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 rkz open seq file FM, simply by entering the name RKZ_OPEN_SEQ_FILE into the relevant SAP transaction such as SE37 or SE38.

Function Group: SIOC
Program Name: SAPLSIOC
Main Program: SAPLSIOC
Appliation area: K
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function RKZ_OPEN_SEQ_FILE 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 'RKZ_OPEN_SEQ_FILE'"Open seq. files /output ,input
EXPORTING
NAME = "Name of the seq. file
* OPTION = 'I' "Input / output option
* OPTIONLENGTH = ' ' "implicit / explicit length
* OVERWRITE = ' ' "Overwriting when repeating OPEN
* MAXLEN = "

IMPORTING
CODE_PAGE = "Code page of the open file
NUMBER_FORMAT = "Number format of the open file

EXCEPTIONS
EOF = 1 INVALID_OPTION = 2 NO_SIOC_FILE = 3 OPEN_2 = 4 OPEN_ERROR = 5
.



IMPORTING Parameters details for RKZ_OPEN_SEQ_FILE

NAME - Name of the seq. file

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

OPTION - Input / output option

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

OPTIONLENGTH - implicit / explicit length

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

OVERWRITE - Overwriting when repeating OPEN

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

MAXLEN -

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

EXPORTING Parameters details for RKZ_OPEN_SEQ_FILE

CODE_PAGE - Code page of the open file

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

NUMBER_FORMAT - Number format of the open file

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

EXCEPTIONS details

EOF - End of file reached

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

INVALID_OPTION - Invalid option

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

NO_SIOC_FILE - File format is unknown

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

OPEN_2 - 2nd Open of the same file

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

OPEN_ERROR - Error opening seq. file

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

Copy and paste ABAP code example for RKZ_OPEN_SEQ_FILE 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_eof  TYPE STRING, "   
lv_name  TYPE HEADA-DSN, "   
lv_code_page  TYPE TCP00-CPCODEPAGE, "   
lv_option  TYPE TCP00, "   'I'
lv_number_format  TYPE TCP00-CPCODEPAGE, "   
lv_invalid_option  TYPE TCP00, "   
lv_no_sioc_file  TYPE TCP00, "   
lv_optionlength  TYPE TCP00, "   SPACE
lv_open_2  TYPE TCP00, "   
lv_overwrite  TYPE TCP00, "   SPACE
lv_maxlen  TYPE ARCH_SIZE, "   
lv_open_error  TYPE ARCH_SIZE. "   

  CALL FUNCTION 'RKZ_OPEN_SEQ_FILE'  "Open seq. files /output ,input
    EXPORTING
         NAME = lv_name
         OPTION = lv_option
         OPTIONLENGTH = lv_optionlength
         OVERWRITE = lv_overwrite
         MAXLEN = lv_maxlen
    IMPORTING
         CODE_PAGE = lv_code_page
         NUMBER_FORMAT = lv_number_format
    EXCEPTIONS
        EOF = 1
        INVALID_OPTION = 2
        NO_SIOC_FILE = 3
        OPEN_2 = 4
        OPEN_ERROR = 5
. " RKZ_OPEN_SEQ_FILE




ABAP code using 7.40 inline data declarations to call FM RKZ_OPEN_SEQ_FILE

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 DSN FROM HEADA INTO @DATA(ld_name).
 
"SELECT single CPCODEPAGE FROM TCP00 INTO @DATA(ld_code_page).
 
DATA(ld_option) = 'I'.
 
"SELECT single CPCODEPAGE FROM TCP00 INTO @DATA(ld_number_format).
 
 
 
DATA(ld_optionlength) = ' '.
 
 
DATA(ld_overwrite) = ' '.
 
 
 


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!