SAP PTRV_TRANSLATE Function Module for









PTRV_TRANSLATE is a standard ptrv translate SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 ptrv translate FM, simply by entering the name PTRV_TRANSLATE into the relevant SAP transaction such as SE37 or SE38.

Function Group: HRTS
Program Name: SAPLHRTS
Main Program: SAPLHRTS
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:



Function PTRV_TRANSLATE 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 'PTRV_TRANSLATE'"
EXPORTING
I_BUDAT = "
I_A_VERD = "
I_G_VERD = "
I_REPLACE = "
* I_BL_K = "Checkbox
* I_PRCTR_TR = "Checkbox
I_SOPER = "
I_BLDAT = "
I_GSBER_A = "
I_GSBER_G = "
I_A_SGTXT = "
I_G_SGTXT = "
I_BLART = "
I_BL_SPL = "

TABLES
T_EP_TRANSLATE = "
T_PTRV_ROT_EP = "
T_PTRV_POST_RESULT = "
T_RETURN_TABLE = "

EXCEPTIONS
ALE_COMMUNICATION_ERROR = 1 FI_CUSTOMIZING_ERROR = 2 NUMBER_RANGE_ERROR = 3
.



IMPORTING Parameters details for PTRV_TRANSLATE

I_BUDAT -

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

I_A_VERD -

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

I_G_VERD -

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

I_REPLACE -

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

I_BL_K - Checkbox

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

I_PRCTR_TR - Checkbox

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

I_SOPER -

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

I_BLDAT -

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

I_GSBER_A -

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

I_GSBER_G -

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

I_A_SGTXT -

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

I_G_SGTXT -

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

I_BLART -

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

I_BL_SPL -

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

TABLES Parameters details for PTRV_TRANSLATE

T_EP_TRANSLATE -

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

T_PTRV_ROT_EP -

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

T_PTRV_POST_RESULT -

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

T_RETURN_TABLE -

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

EXCEPTIONS details

ALE_COMMUNICATION_ERROR -

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

FI_CUSTOMIZING_ERROR -

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

NUMBER_RANGE_ERROR -

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

Copy and paste ABAP code example for PTRV_TRANSLATE 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_i_budat  TYPE RPRXXXXX-BUDAT, "   
lt_t_ep_translate  TYPE STANDARD TABLE OF PTRV_EP, "   
lv_ale_communication_error  TYPE PTRV_EP, "   
lv_i_a_verd  TYPE RPRXXXXX-A_VERD, "   
lv_i_g_verd  TYPE RPRXXXXX-G_VERD, "   
lv_i_replace  TYPE RPRXXXXX-KR_FELD1, "   
lv_i_bl_k  TYPE RPRXXXXX-KR_FELD7, "   
lv_i_prctr_tr  TYPE BOOLE_D, "   
lv_i_soper  TYPE RPRXXXXX-SOPER, "   
lt_t_ptrv_rot_ep  TYPE STANDARD TABLE OF PTRV_ROT_EP, "   
lv_fi_customizing_error  TYPE PTRV_ROT_EP, "   
lv_i_bldat  TYPE RPRXXXXX-BLDAT, "   
lv_number_range_error  TYPE RPRXXXXX, "   
lt_t_ptrv_post_result  TYPE STANDARD TABLE OF PTRV_POST_RESULT, "   
lv_i_gsber_a  TYPE RPRXXXXX-KR_FELD3, "   
lt_t_return_table  TYPE STANDARD TABLE OF BAPIRET2, "   
lv_i_gsber_g  TYPE RPRXXXXX-KR_FELD11, "   
lv_i_a_sgtxt  TYPE RPRXXXXX-KR_FELD4, "   
lv_i_g_sgtxt  TYPE RPRXXXXX-KR_FELD4, "   
lv_i_blart  TYPE RPRXXXXX-BLART, "   
lv_i_bl_spl  TYPE RPRXXXXX-BL_SPL. "   

  CALL FUNCTION 'PTRV_TRANSLATE'  "
    EXPORTING
         I_BUDAT = lv_i_budat
         I_A_VERD = lv_i_a_verd
         I_G_VERD = lv_i_g_verd
         I_REPLACE = lv_i_replace
         I_BL_K = lv_i_bl_k
         I_PRCTR_TR = lv_i_prctr_tr
         I_SOPER = lv_i_soper
         I_BLDAT = lv_i_bldat
         I_GSBER_A = lv_i_gsber_a
         I_GSBER_G = lv_i_gsber_g
         I_A_SGTXT = lv_i_a_sgtxt
         I_G_SGTXT = lv_i_g_sgtxt
         I_BLART = lv_i_blart
         I_BL_SPL = lv_i_bl_spl
    TABLES
         T_EP_TRANSLATE = lt_t_ep_translate
         T_PTRV_ROT_EP = lt_t_ptrv_rot_ep
         T_PTRV_POST_RESULT = lt_t_ptrv_post_result
         T_RETURN_TABLE = lt_t_return_table
    EXCEPTIONS
        ALE_COMMUNICATION_ERROR = 1
        FI_CUSTOMIZING_ERROR = 2
        NUMBER_RANGE_ERROR = 3
. " PTRV_TRANSLATE




ABAP code using 7.40 inline data declarations to call FM PTRV_TRANSLATE

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 BUDAT FROM RPRXXXXX INTO @DATA(ld_i_budat).
 
 
 
"SELECT single A_VERD FROM RPRXXXXX INTO @DATA(ld_i_a_verd).
 
"SELECT single G_VERD FROM RPRXXXXX INTO @DATA(ld_i_g_verd).
 
"SELECT single KR_FELD1 FROM RPRXXXXX INTO @DATA(ld_i_replace).
 
"SELECT single KR_FELD7 FROM RPRXXXXX INTO @DATA(ld_i_bl_k).
 
 
"SELECT single SOPER FROM RPRXXXXX INTO @DATA(ld_i_soper).
 
 
 
"SELECT single BLDAT FROM RPRXXXXX INTO @DATA(ld_i_bldat).
 
 
 
"SELECT single KR_FELD3 FROM RPRXXXXX INTO @DATA(ld_i_gsber_a).
 
 
"SELECT single KR_FELD11 FROM RPRXXXXX INTO @DATA(ld_i_gsber_g).
 
"SELECT single KR_FELD4 FROM RPRXXXXX INTO @DATA(ld_i_a_sgtxt).
 
"SELECT single KR_FELD4 FROM RPRXXXXX INTO @DATA(ld_i_g_sgtxt).
 
"SELECT single BLART FROM RPRXXXXX INTO @DATA(ld_i_blart).
 
"SELECT single BL_SPL FROM RPRXXXXX INTO @DATA(ld_i_bl_spl).
 


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!