SAP Function Modules

HRGPBS_FILE_SERVER_EXPORT SAP Function module - Export File To File Server







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

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


Pattern for FM HRGPBS_FILE_SERVER_EXPORT - HRGPBS FILE SERVER EXPORT





CALL FUNCTION 'HRGPBS_FILE_SERVER_EXPORT' "Export File To File Server
  EXPORTING
    p_filename =                " p08_ussc12
    p_record_length =           " i
    p_logical_filename =        " fileintern    Logical file name
  TABLES
    p_interface =               "
    p_error =                   " edimessage
    .  "  HRGPBS_FILE_SERVER_EXPORT

ABAP code example for Function Module HRGPBS_FILE_SERVER_EXPORT





The ABAP code below is a full code listing to execute function module HRGPBS_FILE_SERVER_EXPORT 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_p_interface  TYPE STANDARD TABLE OF STRING,"TABLES PARAM
wa_p_interface  LIKE LINE OF it_p_interface ,
it_p_error  TYPE STANDARD TABLE OF EDIMESSAGE,"TABLES PARAM
wa_p_error  LIKE LINE OF it_p_error .

DATA(ld_p_filename) = 'Check type of data required'.
DATA(ld_p_record_length) = 'Check type of data required'.
DATA(ld_p_logical_filename) = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_p_interface to it_p_interface.

"populate fields of struture and append to itab
append wa_p_error to it_p_error. . CALL FUNCTION 'HRGPBS_FILE_SERVER_EXPORT' EXPORTING p_filename = ld_p_filename p_record_length = ld_p_record_length p_logical_filename = ld_p_logical_filename TABLES p_interface = it_p_interface p_error = it_p_error . " HRGPBS_FILE_SERVER_EXPORT
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_p_filename  TYPE P08_USSC12 ,
it_p_interface  TYPE STANDARD TABLE OF STRING ,
wa_p_interface  LIKE LINE OF it_p_interface,
ld_p_record_length  TYPE I ,
it_p_error  TYPE STANDARD TABLE OF EDIMESSAGE ,
wa_p_error  LIKE LINE OF it_p_error,
ld_p_logical_filename  TYPE FILEINTERN .

ld_p_filename = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_p_interface to it_p_interface.
ld_p_record_length = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_p_error to it_p_error.
ld_p_logical_filename = 'Check type of data required'.

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