SAP RP_TS_OPEN Function Module for Open an HR TemSe object









RP_TS_OPEN is a standard rp ts open 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 an HR TemSe object 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 rp ts open FM, simply by entering the name RP_TS_OPEN into the relevant SAP transaction such as SE37 or SE38.

Function Group: RPTS
Program Name: SAPLRPTS
Main Program:
Appliation area: P
Release date: 30-Mar-1995
Mode(Normal, Remote etc): Normal Function Module
Update:



Function RP_TS_OPEN 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 'RP_TS_OPEN'"Open an HR TemSe object
EXPORTING
TSOBJ = "Name of TemSe object
EMPFG = "Recipient
* VERSN = '01' "Version number
* OWNNR = ' ' "Own FM handling (several TemSe objects)
* ENQLOCK = 'N' "

IMPORTING
OBJHD = "File block handle for the TemSe object
VERSN = "Version number
OBJIN = "Object information

EXCEPTIONS
FB_CALL_HANDLE = 1 ENQ_FOREIGN_LOCK = 10 ENQ_SYS_FAIL = 11 ENQ_OTHER = 12 FB_ERROR = 2 FB_RSTS_NOCONV = 3 FB_RSTS_OTHER = 4 NO_OBJECT = 5 NO_PERMISSION = 6 NO_HR_APPLICATION_FILE = 7 INVALID_VERSION_NUMBER = 8 WRONG_REPORT = 9
.



IMPORTING Parameters details for RP_TS_OPEN

TSOBJ - Name of TemSe object

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

EMPFG - Recipient

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

VERSN - Version number

Data type: RPTSTYPE-VERSN
Default: '01'
Optional: Yes
Call by Reference: No ( called with pass by value option)

OWNNR - Own FM handling (several TemSe objects)

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

ENQLOCK -

Data type: RSTSTYPE-PROM
Default: 'N'
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for RP_TS_OPEN

OBJHD - File block handle for the TemSe object

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

VERSN - Version number

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

OBJIN - Object information

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

EXCEPTIONS details

FB_CALL_HANDLE - Error with handles at the CALL interface

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

ENQ_FOREIGN_LOCK -

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

ENQ_SYS_FAIL -

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

ENQ_OTHER -

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

FB_ERROR - Error in/at function module

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

FB_RSTS_NOCONV - Required conversion not possible

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

FB_RSTS_OTHER - TemSe C system - other errors reported

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

NO_OBJECT - Required TemSe object does not exist

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

NO_PERMISSION - No authorization for this operation

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

NO_HR_APPLICATION_FILE - File was not created using HR application

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

INVALID_VERSION_NUMBER - Version number invalid

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

WRONG_REPORT - This file is not intended for this report

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

Copy and paste ABAP code example for RP_TS_OPEN 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_objhd  TYPE RPTSTYPE-OBJHD, "   
lv_tsobj  TYPE RPTSTYPE-TSOBJ, "   
lv_fb_call_handle  TYPE RPTSTYPE, "   
lv_enq_foreign_lock  TYPE RPTSTYPE, "   
lv_enq_sys_fail  TYPE RPTSTYPE, "   
lv_enq_other  TYPE RPTSTYPE, "   
lv_empfg  TYPE RPTSTYPE-EMPFG, "   
lv_versn  TYPE RPTSTYPE-VERSN, "   
lv_fb_error  TYPE RPTSTYPE, "   
lv_objin  TYPE RPTSTYPE-OBJIN, "   
lv_versn  TYPE RPTSTYPE-VERSN, "   '01'
lv_fb_rsts_noconv  TYPE RPTSTYPE, "   
lv_ownnr  TYPE RPTSTYPE-OWNNR, "   ' '
lv_fb_rsts_other  TYPE RPTSTYPE, "   
lv_enqlock  TYPE RSTSTYPE-PROM, "   'N'
lv_no_object  TYPE RSTSTYPE, "   
lv_no_permission  TYPE RSTSTYPE, "   
lv_no_hr_application_file  TYPE RSTSTYPE, "   
lv_invalid_version_number  TYPE RSTSTYPE, "   
lv_wrong_report  TYPE RSTSTYPE. "   

  CALL FUNCTION 'RP_TS_OPEN'  "Open an HR TemSe object
    EXPORTING
         TSOBJ = lv_tsobj
         EMPFG = lv_empfg
         VERSN = lv_versn
         OWNNR = lv_ownnr
         ENQLOCK = lv_enqlock
    IMPORTING
         OBJHD = lv_objhd
         VERSN = lv_versn
         OBJIN = lv_objin
    EXCEPTIONS
        FB_CALL_HANDLE = 1
        ENQ_FOREIGN_LOCK = 10
        ENQ_SYS_FAIL = 11
        ENQ_OTHER = 12
        FB_ERROR = 2
        FB_RSTS_NOCONV = 3
        FB_RSTS_OTHER = 4
        NO_OBJECT = 5
        NO_PERMISSION = 6
        NO_HR_APPLICATION_FILE = 7
        INVALID_VERSION_NUMBER = 8
        WRONG_REPORT = 9
. " RP_TS_OPEN




ABAP code using 7.40 inline data declarations to call FM RP_TS_OPEN

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 OBJHD FROM RPTSTYPE INTO @DATA(ld_objhd).
 
"SELECT single TSOBJ FROM RPTSTYPE INTO @DATA(ld_tsobj).
 
 
 
 
 
"SELECT single EMPFG FROM RPTSTYPE INTO @DATA(ld_empfg).
 
"SELECT single VERSN FROM RPTSTYPE INTO @DATA(ld_versn).
 
 
"SELECT single OBJIN FROM RPTSTYPE INTO @DATA(ld_objin).
 
"SELECT single VERSN FROM RPTSTYPE INTO @DATA(ld_versn).
DATA(ld_versn) = '01'.
 
 
"SELECT single OWNNR FROM RPTSTYPE INTO @DATA(ld_ownnr).
DATA(ld_ownnr) = ' '.
 
 
"SELECT single PROM FROM RSTSTYPE INTO @DATA(ld_enqlock).
DATA(ld_enqlock) = 'N'.
 
 
 
 
 
 


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!