Sei sulla pagina 1di 19

Function TIMTP

Introduction

You might be thinking why a standard function deserves a knowledge artifact. Well, to be
frank, when I was learning time management on my own, this was one of the functions
which I wasnt able to understand completely. I attended a training later where I finally
understood how function TIMTP works. I have also seen queries in SCN regarding this
function and hence, I thought it would be a good idea to explain its functioning in detail.

Functionality

Before I go into detailed functionality, let me explain you why I couldnt understand
TIMTP function. The reason was that I didnt pay enough attention to Table TIP. We need
to first understand Table TIP and Table V_T555Z before we can understand TIMTP
function.
Table TIP

Table TIP is an internal table used in time evaluation. It contains time pairs which get
processed, changed and made available for further processing. The Table TIP with time
pairs get processed by function in a PCR and the output gets stored again in Table TIP.
This table TIP becomes the input for the next stage. Below is an example of this scenario.

Below is a snapshot of Table TIP.

I will now walk you through each field in this table and explain its meaning. Once we have
understanding of Table TIP, we will move on to function TIMTP.

From: This field displays the Clock In time or Start Time of the time pair. The values get
displayed in decimalized form. Hence, 8:30 will get displayed as 8.5000.

To: This field displays the Clock Out time or End Time of the time pair. The values get
displayed in decimalized form. Hence, 17:30 will get displayed as 17.5000.

1: This field displays the status of time pair formation for time pairs. It can have the below
values:

o
o
o
o
o
o
o
o

0 or Blank
2
3
4
5
7
8
E
order data.
A

Time pair is complete


No Clock In
No Clock Out
No end time for break
No start time for break
No start time for Off Site work
No end time for Off Site work
Order confirmation missing. This status may appear when entering

Pair delimited in time evaluation

P: This field denotes the pair type of the time pair. The functionality of pair type is to specify
the source of time pair whether this time pair is coming from IT2011 (Time Events) or
IT2001 (Absences) or IT2002 (Attendances) or non-recorded times. This field is important as it is used by
function TIMTP to assign time types and processing types to time pairs. Below are the possible values of pair types for
time pairs:

0
This refers to non-recorded time. In case of positive time management, time
recording is required during the planned timings for working days. If there is no time
recorded during the planned working time, this period of time pair appears with pair type 0.
Let us say that the shift timings are from 9:00 18:00. Employee clocks in at 9:00 and
clocks out at 11:00 and again clocks in at 11:30 and clocks out at 18:00. The time pair
11:00 11:30 will appear with pair type 0 which is a non-recorded time.

1
It implies that the employee is at work. In case of positive time
management, it will have data from IT2011 Time Events Infotype. In case of negative
time management, it will have planned pair according to daily workschedule.

2
It implies that the employee is absent. It will have data from IT2001
Absences Infotype.

3
It implies off site work or recorded attendances have data from IT2002
Attendances Infotype.

ID: This field classifies the time pair in relation to the daily work schedule. This field is important as it
is used by function TIMTP to assign time types and processing types to time pairs. Below are the possible values for ID:

01
schedule)

Overtime (This ID is assigned to any time pair outside the daily work

02

Fill time (Assigned to time pair within the daily work schedule)

03
schedule)

Core time (Assigned to time pair if core time is defined in daily work

04
Core time break (Assigned to time pair if core time break is defined in
daily work schedule)

05
work schedule)

Fill time break (Assigned to time pair if fill time break is defined in daily

06
schedule)

Paid break (Assigned to time pair if paid break is defined in daily work

07
is defined)

Unpaid overtime break (Assigned to time pair if unpaid overtime break

08
defined)

Paid overtime break (Assigned to time pair if paid overtime break is

09

Overtime break (Assigned to time pair if overtime break is defined)

CT: This field represents the Processing Type/Time Type Class and is used to group absence
and attendance types which are to be processed identically in time evaluation. It is also
used to assign time types to time pairs from Table T555Y in case of negative time
management (schema TM04).

P: This field represents the processing type of the time pair. Processing type is used in
generation of wage types from Time Wage Type Selection Table T510S. In some scenarios,
function TIMTP assigns processing type to time pairs based on the configuration defined in
Table V_T555Z. Below are the possible values of processing types:

Pair is deleted at later stage

o
o

Blank
S

Pair is not counted as productive time


Planned Working Time Pair

o
o
o
o

M
A
P
K

TTyp: This field represents the time type assigned to time pair. In some scenarios, function
TIMTP assigned time type to time pairs based on the configuration defined in Table
V_T555Z. These time types are defined in Table V_T555A.

BR: This field represents the time event type of the begin entry.

ER: This field represents the time event type of the end entry.

C: This field represents the overtime compensation type. It is used to determine whether
the employee should receive remuneration and/or time off for working overtime. I havent
used this field till now. Below are the possible values:

o
o
o
o

Blank
1
2
3

I: This field represents internal key for availability duty and is meant for Germany only. I
havent used this field till now.

BPIN: This field represents the attendance/ absence reason for begin entry. It is used in
positive time management where the time recording system supports to capture
attendance/ absence reasons.

EPIN: This field represents the attendance/ absence reason for end entry. It is used in
positive time management where the time recording system supports to capture
attendance/ absence reasons.

PT: This field represents the pointer to time pairs from time events. It contains the no. of
the line in Table PT (pair table) which contains the time pair from which the current TIP
entry was derived.

ALP: This field represents the pointer to alternative payment.

C1: This field represents the pointer to cost distribution.

AB: This field represents the pointer to absence pairs.

Number: This field represents the no. of hours of time pair in decimalized form.

Overtime time pair


Absence pair included in the calculation of planned working time
Attendance pair included in the calculation of planned working time
Core night work (valid for Germany only)

Remuneration
Remuneration (basic pay plus overtime hours)
Basic Pay
Compensation (time off)

Table V_T555Z Time Type Determination

Table V_T555Z Time Type Determination is used by function TIMTP to assign time types
and processing types to time pairs in Table TIP. Below is a snapshot of the table
V_T555Z.

Let us understand the different columns in Time Type Determination Table.

PSGpg: This field represents the personnel subareas grouping for time recording. It is
defined in Table V_001P_All under field TRec.

Group: This field represents the time type determination group. Function MOD processes
PCR MODT in schema TM00 and uses operation MODIF T to set the time type determination
group for the given employee. Function TIMTP uses PSGpg and Group to assign time types
and processing types to time pairs in Table TIP in positive time evaluation.

ID: This field classifies the time pair in relation to the daily work schedule. This field is important as it
is used by function TIMTP to assign time types and processing types to time pairs. Below are the possible values for ID:

01
schedule)

Overtime (This ID is assigned to any time pair outside the daily work

02

Fill time (Assigned to time pair within the daily work schedule)

03
schedule)

Core time (Assigned to time pair if core time is defined in daily work

04
Core time break (Assigned to time pair if core time break is defined in
daily work schedule)

05
work schedule)

Fill time break (Assigned to time pair if fill time break is defined in daily

06
schedule)

Paid break (Assigned to time pair if paid break is defined in daily work

07
is defined)

Unpaid overtime break (Assigned to time pair if unpaid overtime break

08
defined)

Paid overtime break (Assigned to time pair if paid overtime break is

09

Overtime break (Assigned to time pair if overtime break is defined)

PType0
This field represents the processing type for non-recorded time
for each combination of PSGgp, Group and ID.

TType0
This field represents the time type for non-recorded time for
each combination of PSGgp, Group and ID.

PType1
This field represents the processing type for time pairs from
IT2011 or planned working time for each combination of PSGgp, Group and ID.

TType1
This field represents the time type for time pairs from IT2011 or
planned working time for each combination of PSGgp, Group and ID.

PType2
This field represents the processing type for time pairs from
IT2001 for each combination of PSGgp, Group and ID.

TType2
This field represents the time type for time pairs from IT2001 for
each combination of PSGgp, Group and ID.

PType3
This field represents the processing type for time pairs from
IT2002 for each combination of PSGgp, Group and ID.

TType3
This field represents the time type for time pairs from IT2002 for
each combination of PSGgp, Group and ID.

Start Date

This field represents the start date for the record.

End Date

This field represents the end date for the record.

Function TIMTP

Function TIMTP can be accessed using TCode PE04. The input and output parameters of
the function are as shown below. These internal tables will appear in input and output
section of the function TIMTP.

Function TIMTP performs three key tasks:


1. It compares the time pairs in Table TIP with the times in daily work schedule using
Table TZP. Time pairs may also be split so that time pairs can be uniquely classified with
regards to the planned working time as core time, fill time, overtime, core time break, fill
time break, overtime break, paid break, unpaid overtime break or paid overtime break.
After the time pairs split, each time pair is assigned a unique time id based on its position in
the planned working time. If the time pair had a time identifier before function TIMTP, it
remains the same after processing.
2. It generates time pairs with pair type 0 for times for which there is no time data within
the planned working time. In case of positive time management, time recording is required
during the planned timings for working days. If there is no time recorded during the planned
working time, this period of time pair appears with pair type 0. Let us say that the shift
timings are from 9:00 18:00. Employee clocks in at 9:00 and clocks out at 11:00 and

again clocks in at 11:30 and clocks out at 18:00. The time pair 11:00 11:30 will appear
with pair type 0 which is a non-recorded time.
3. It assigns processing type and time type to time pairs in Table TIP according to Time
Type Determination Table V_T555Z. It reads the time type determination table using PSG
Grouping for Time Recording, Time Type Determination Group, Time Id and pair type of
each time pair and assigns a unique processing type and time type to the time pair in Table
TIP. If the time pair already had a processing type and time type before TIMTP, it remains
the same after processing.

Function TIMTP Processing

Let me take you through a live time evaluation run to explain the processing of TIMTP
function. Below are the key data in time infotypes which will get processed.
IT0001

Daily Work Schedule

Break Timings

IT2011

The shift timings for the employee are from 9:00 17:00 with 1 hour break from 12:00
13:00. The employee clocks in at 08:50:00 before shift start time (9:00:00) and clocks
out at 10:20:00. He again clocks in back at 11:00:00 and clocks out at 15:00:00. He
clocks in back at 15:30:00 and clocks out at 18:45:00 after shift end time (17:00:00).

IT2002

Attendances have been captured for 01-Aug-13 as shown below:

For the purpose of explanation, I have kept parameter 1 for functions P2001 and P2002
blank so that the time pairs from infotypes IT2001 and IT2002 dont overwrite the time
pairs from IT2011. Please refer the below screenshot.

Time Evaluation Run

Time Evaluation runs successfully

Operation MODIF has set Time Type Determination Group as T=01 as shown in the below
screenshot.

Based on personnel area and personnel subarea, the PSG grouping for time recording is
01 from Table V_001P_All.

Based on PSG Grouping for Time Recording and Time Type Determination Group, below
are the rows which will be applicable for the employee from Time Type Determination
Table V_T555Z. This is a configuration table and you can maintain your own specific
values for processing type and time type for each combination of PSG Grouping, Time
Type Determination Group and Time Id. I would, however, recommend not to touch the
standard values supplied by SAP. Instead, you create your own custom values by using a
different PSG Grouping and Time Type Determination Group. Whenever you create your
own values for processing types and time types, please ensure that you copy all the rows
from ID 01 to 09 from a given PSG Grouping and Time Type Determination Group to your
own PSG Grouping and Time Type Determination Group and then make changes to it.

Input for Function TIMTP

Table TZP displays the timings in decimalized format from 00:00 hours onwards and
assigns time id to it. In the above case, from 00:00 hours till 09:00 hours, the time id
assigned is 01 since this time is outside the planned working times. From 09:00 hours till
12:00 hours and from 13:00 hours till 17:00 hours, the time id assigned is 02 since this
time is the fill time within the planned working times. From 12:00 hours till 13:00 hours,
the time id assigned is 05 since this is the break time. Since it is a paid break, it displays
as 1 in the paid break period.
Table TIP displays the time pairs with their pair types and processing types. Any time pair
with pair type 1 means that this time is coming from IT2011. Any time pair with pair type
3 means that this time is coming from IT2002.
Table P2002 displays all the attendance requests for the given date.
I will now explain how function TIMTP will process the time pairs present in Table TIP.
Let us take the first time pair with pair type 1 and with timings from 08.8333 till 10.3333.
This time pair is overlapping across planned working times (9.0000 18.0000) and nonplanned working times. Hence, the function TIMTP will first split the time pair into two
time pairs and assigns time ids as below:
1.
2.

08.8333 09.0000 with Time Id 01 (overtime) and pair type 1.


09.0000 10.3333 with Time Id 02 (fill time) and pair type 1.

After doing this split, the function will refer to time type determination table for pair type
1 and time ids 01 and 02 and will assign the processing type and time type according to
the configuration value maintained there. If you refer to the table V_T555Z, you will find
that for pair type 1 and time id 02, the processing type is P and time type is 0110 (refer
intersection point of red and blue boxes).

In case of time pair with pair type 1 and time id 01, the processing type is blank and the
time type is 0310 (refer intersection point of red and blue boxes).

Hence, the time pairs in output Table TIP look like below:

The next time pair in input Table TIP is from 10.0000 12.0000 with pair type 3 (data
coming from IT2002). Since this time falls within the fill time of planned working time, the
function assigns time id 02 to it and time 0130 by referring to Table V_T555Z for pair
type 3 and time id 02. The time pair had processing type P assigned from before and
hence, it remains the same.
You will find in the above example that there is no time pair from 10.3333 till 11.0000
with pair type 0 because there is an attendance record from 10.0000 till 12.0000 (pair
type 3).
The function then picks up the next time pair with pair type 1 and from 11.0000 till
15.0000 and splits it into three time pairs and assigns time ids as shown below:
1.
2.
3.

11.0000 12.0000 with Time Id 02 and pair type 1.


12.0000 13.0000 with Time Id 05 (break time) and pair type 1.
13.0000 15.0000 with Time Id 02 and pair type 1.

After the split, the function refers to Time Type Determination table for pair type 1 and
time ids 02 and 05 and respectively assigns the time type and processing type.
Hence, the output TIP table looks like below:

Now, for the period from 15.0000 till 15.3000 of the planned working time, there is no
data from IT2011 or IT2002 or IT2001. Hence, the function creates a time pair with
timings 15.0000 15.5000 with pair type 0 and time id 02 (because this time is fill time
within the planned working time). Based on the pair type 0 and time id 02, it refers to
time type determination table to assign processing type K and time type 0000 to the time
pair.
The function then splits the next time pair with pair type 1 and timings 15.5000
18.7500 into two time pairs and assigns time ids as shown below:
1.
2.

15.5000 17.0000 with Time Id 02 (fill time) and pair type 1.


17.0000 18.7500 with Time Id 01 (overtime) and pair type 1.

After doing this split, the function will refer to time type determination table for pair type
1 and time ids 01 and 02 and will assign the processing type and time type to the time
pairs as shown below:

The function then processes the last time pair in input table TIP with pair type 3 and
timings 19.0000 21.0000 and assigns it time id 01 (overtime). It refers to time type
determination table for time id 01 and pair type 3 and assigns time type 0330 to the time
pair.

Here, I come to the end of this knowledge artifact. I hope you have a better
understanding of this crucial function TIMTP after going through this document.

Potrebbero piacerti anche