SAP TG_CHECK_OVERLAP Function Module for









TG_CHECK_OVERLAP is a standard tg check overlap 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 tg check overlap FM, simply by entering the name TG_CHECK_OVERLAP into the relevant SAP transaction such as SE37 or SE38.

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



Function TG_CHECK_OVERLAP 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 'TG_CHECK_OVERLAP'"
EXPORTING
HEAD_DATV1 = "Start Date of Trip Segment
HEAD_DATB1 = "End Date of Trip Segment
HEAD_UHRV1 = "Beginning Time of Trip Segment
HEAD_UHRB1 = "End Time of Trip Segment
EMPLOYEE_NUMBER = "Personnel Number
AKT_REINR = "Trip Number
* CHANGE_FLAG = ' ' "

IMPORTING
TG_DATV1 = "Start Date of Trip Segment
TG_DATB1 = "End Date of Trip Segment
TG_UHRV1 = "Indicator for definition of statutory trip types
TG_UHRB1 = "End Time of Trip Segment
TG_TYPE = "Indicator for definition of statutory trip types
OVERLAP = "Single-Character Indicator
.



IMPORTING Parameters details for TG_CHECK_OVERLAP

HEAD_DATV1 - Start Date of Trip Segment

Data type: PTP02-DATV1
Optional: No
Call by Reference: Yes

HEAD_DATB1 - End Date of Trip Segment

Data type: PTP02-DATB1
Optional: No
Call by Reference: Yes

HEAD_UHRV1 - Beginning Time of Trip Segment

Data type: PTP02-UHRV1
Optional: No
Call by Reference: Yes

HEAD_UHRB1 - End Time of Trip Segment

Data type: PTP02-UHRB1
Optional: No
Call by Reference: Yes

EMPLOYEE_NUMBER - Personnel Number

Data type: PTP02-PERNR
Optional: No
Call by Reference: Yes

AKT_REINR - Trip Number

Data type: PTP02-REINR
Optional: No
Call by Reference: Yes

CHANGE_FLAG -

Data type: CHAR1
Default: SPACE
Optional: No
Call by Reference: Yes

EXPORTING Parameters details for TG_CHECK_OVERLAP

TG_DATV1 - Start Date of Trip Segment

Data type: PTP02-DATV1
Optional: No
Call by Reference: Yes

TG_DATB1 - End Date of Trip Segment

Data type: PTP02-DATB1
Optional: No
Call by Reference: Yes

TG_UHRV1 - Indicator for definition of statutory trip types

Data type: PTP02-UHRV1
Optional: No
Call by Reference: Yes

TG_UHRB1 - End Time of Trip Segment

Data type: PTP02-UHRB1
Optional: No
Call by Reference: Yes

TG_TYPE - Indicator for definition of statutory trip types

Data type: T702G-GESKZ
Optional: No
Call by Reference: Yes

OVERLAP - Single-Character Indicator

Data type: CHAR1
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for TG_CHECK_OVERLAP 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_tg_datv1  TYPE PTP02-DATV1, "   
lv_head_datv1  TYPE PTP02-DATV1, "   
lv_tg_datb1  TYPE PTP02-DATB1, "   
lv_head_datb1  TYPE PTP02-DATB1, "   
lv_tg_uhrv1  TYPE PTP02-UHRV1, "   
lv_head_uhrv1  TYPE PTP02-UHRV1, "   
lv_tg_uhrb1  TYPE PTP02-UHRB1, "   
lv_head_uhrb1  TYPE PTP02-UHRB1, "   
lv_tg_type  TYPE T702G-GESKZ, "   
lv_employee_number  TYPE PTP02-PERNR, "   
lv_overlap  TYPE CHAR1, "   
lv_akt_reinr  TYPE PTP02-REINR, "   
lv_change_flag  TYPE CHAR1. "   SPACE

  CALL FUNCTION 'TG_CHECK_OVERLAP'  "
    EXPORTING
         HEAD_DATV1 = lv_head_datv1
         HEAD_DATB1 = lv_head_datb1
         HEAD_UHRV1 = lv_head_uhrv1
         HEAD_UHRB1 = lv_head_uhrb1
         EMPLOYEE_NUMBER = lv_employee_number
         AKT_REINR = lv_akt_reinr
         CHANGE_FLAG = lv_change_flag
    IMPORTING
         TG_DATV1 = lv_tg_datv1
         TG_DATB1 = lv_tg_datb1
         TG_UHRV1 = lv_tg_uhrv1
         TG_UHRB1 = lv_tg_uhrb1
         TG_TYPE = lv_tg_type
         OVERLAP = lv_overlap
. " TG_CHECK_OVERLAP




ABAP code using 7.40 inline data declarations to call FM TG_CHECK_OVERLAP

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 DATV1 FROM PTP02 INTO @DATA(ld_tg_datv1).
 
"SELECT single DATV1 FROM PTP02 INTO @DATA(ld_head_datv1).
 
"SELECT single DATB1 FROM PTP02 INTO @DATA(ld_tg_datb1).
 
"SELECT single DATB1 FROM PTP02 INTO @DATA(ld_head_datb1).
 
"SELECT single UHRV1 FROM PTP02 INTO @DATA(ld_tg_uhrv1).
 
"SELECT single UHRV1 FROM PTP02 INTO @DATA(ld_head_uhrv1).
 
"SELECT single UHRB1 FROM PTP02 INTO @DATA(ld_tg_uhrb1).
 
"SELECT single UHRB1 FROM PTP02 INTO @DATA(ld_head_uhrb1).
 
"SELECT single GESKZ FROM T702G INTO @DATA(ld_tg_type).
 
"SELECT single PERNR FROM PTP02 INTO @DATA(ld_employee_number).
 
 
"SELECT single REINR FROM PTP02 INTO @DATA(ld_akt_reinr).
 
DATA(ld_change_flag) = ' '.
 


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!