cancel
Showing results for 
Search instead for 
Did you mean: 

Time Evaluation in case of Night Shift

ankitvasavada
Active Contributor
0 Kudos

Dear Gurus

I am tring to configure the shift which start from 19:00 and end next day 4:00.

My config is working fine with day shift. and it is calulating over time and short time and planned time corractly.

By when I configure the night shift it is not calulating properly.

problem come after 24:00.

Please help me.

Regards

Ankit Vasavada    

Accepted Solutions (1)

Accepted Solutions (1)

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

Let me explain what you have in TIP table. This is for first case(07:45 to 15:45).

Have a look at ID column. This column in TIP table is the same as in V_T555Z. In ID column you have just 01 and 02.

If you go into V_T555Z and press F1 on ID column you find definition for Id 01 to 09.

Column "ID" is time identifier for daily work schedule(DWS)

- 01: not approved overtime, out of planned time. As you see EE has start the work before its planned time.

- 02: work in planned time

As you see EE has a clock-in in 06:47. So system assigns ID 01 for first row of TIP table. Means EE has work out of his/her DWS.

Now go to TTyp column which system has assigned 0310. This is type type which comes from V_T555Z pair typr 0 to pair type 3. If you check it out in V_T555Z type time 0301 is pair type 1.

As you know:

pair type 0 means not at work

pair type 1 means at work(present)

pair type 2 absence

pair type 3 off-site work

As you see EE has work from 06:47 to 07:45(start of DWS) so system assign pair type 1 for TTyp.

I hope you have go how system works in this way. For a similar case I have some detailed explanations at http://scn.sap.com/message/14348140#14348140 also

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

This is a really helpful explanation. cleared lots of questions in my mind.

and not time type and pair type till timtp are corrct as shown in the image.

For us breaks are 1 hour break any time in entire day within work schedule. where in employee can take any number of breaks may be 15 min or half n hour or so. if employee exceeds the 1 hour that is also ok but it will show as extra break hours. I wrote the PCR for Extra break hours. bur after PBRKS there is no extra breaks being calculated. as  Attendance status is 0 as employee is on break or absent.

My breaks defined as in table V_T550P

when I see out put of DEFPT it is concedering only one hour break.

and time type I have changed in table T555Z for combination of 0 05 ad 0510.

so if extended break hours will come in to 05 it will work.

This is probebly the last thing which I am facing.

Thanks in advance for the help.

Thanks and regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

As I understood EE can take any hours of break but based on your customization you have fixed just 1 hour as a break during planned working time so system will consider just 1 hour as break not any more.

I think if EE can take any number of hours as break you should customize it the same as planned number of hours for work. In your case the break time should be 9 hours.

I did not understand this part: "I have changed in table T555Z for combination of 0 05 ad 0510." I recommended to don't touch V_T555Z. if you need to change time types you should change during TIP table processing in schema.

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

Could you please guide me how to change time type in table tip during Schema.

I can apply a logic like if  within planned working time there any combination of 0 and Time type 0000 then change it to 0 0510. that would sove my issue.

Please corrct me if I am wrong. but how to do it. that is again a question...

Thanks and regards

Ankit Vasavada

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

Adding to it

If I put 8 hours as break hours then it is taking complete shift as break...

Regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

I hope you got why you should keep V_T555Z as standard. Because it's a fix setting and for example if in another case you got it should change 0  0000 to y  xxxx other than 0   0510, you can't touch it again.

Anyway, let me explain how you can do it. For example go and have look at PCR TO20 in a case you have overtime. For example in below screens you see the input TIP table has 1   0310 which should consider as overtime because DWS is 07:00 to 16:00

Input

Process

Output

So one way is using standard functions. In this case you should realize what you are going to do and in which steps, which function can help you.

Although there are some functions which you can manipulate TIP table by them but I don't recommend to use it.

Other method is using, for example TR10 PCR. Have a look at it. This PCR separate daily time types without touching TIP table. In this way you can create / update you own time types like a counter.

Ankit for your case I recommend go PCRs one by one to see why you have 0   0000 and system does not change it to anything else. Maybe you have disabled some standard PCRs. Please make sure you have a complete schema.

And for break I have no idea really. It's a bit strange to have 8 or 9 hours as break. I think client should fix it for example break can't be more than a fix and small hours like 1, 1.5 or 2 hours.

Regards,

Omid

former_member193652
Active Contributor
0 Kudos

By the way, you can make a copy of TR10 and change it as you need. You see I have done it.

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

I have checked from my time recording system that Break start time event will not come before Clock - in by mistake also.

so I wrote a PCR that when Time event is P15 then conceder for break.

That solved my issue. Now some 1 2 small issue which I can resolve from small changes in PCR.

Thanks for all your supprt. Really Greatful to you..

Thanks and regards

Ankit Vasavada

Former Member
0 Kudos

Hi Ankit,

How did you manage to solve extra break capturing issue, which PCR helped, can you please help me with some clues.

Ours is variable break.

Regards

Tandrima

ankitvasavada
Active Contributor
0 Kudos

Hi Tandrima

I wrote a PCR which reads the TIP table and take time pair as P15. and accumulate the hours and put in to break hours.

We have another rule that if employee takes the break more then one hour then it should reflect in extra hours.

So one more PCR. which creates the custom time type as extra break hours and we can display it to reprorts.

Hope this helps you.

Regards

Ankit Vasavada

Former Member
0 Kudos

Thanks for the reply Ankit, just wanted to understand more about the 1st PCR, did u just read P15 through OUTTPBRTYP operation, now how you accumulate the hours into break hours. Did you ready end of break too i.e. P25.

Please help

Regards

Tandrima

ankitvasavada
Active Contributor
0 Kudos

Dear Tandrima

First of all Sorry for delay in reply.

Yes we Use this operation.

And no we did not take end of break in to account. as when there is a end of break happen in TIP there is a new row which we need to consider as working time.

Hope this help.

regards

Ankit Vasavada

Answers (4)

Answers (4)

Former Member
0 Kudos

Ankit Hi,

Can you send us screenshot of P2011 function?

Because SAP can combine clock in clock outs as below:

Employee comes to work at 19:00 and leaves in 04:00

In some cases SAP shows this as 19:00-28:00

And if you generate time wage types in time evaluation by using table V_T510S it does not read when you enter 19:00-04:00

You shall enter 19:00-28:00

Have you tried this?

ankitvasavada
Active Contributor
0 Kudos

Dear Okan

Where I have to enter 19:00 to 28:00 as I can not enter 28:00 in Infotype 2011.

Screenshot of p2011 is attached.

Thanks and regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

Okan talking about V_T510S.

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid/ Okan

As far as I understand the system that I need to do some changes in Table T555Z. as now I can see for both the cases become same by the time type which is getting assgned based on Time identifier is 0000 in case 2. that why it is deleting.

Please suggest with the entry in T555Z.

Case 1 Function TIMTP

Case 2 Function TIMTP

Table T555Z

Hope for early help.

Regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

Although you can touch T555Z but I strongly recommend to don't touch it. Because if you touch it you can't use almost standard PT reports. I see your version has changes. Please have a look the same lines in table for grouping 01(Your grouping is 71)

If you have kept this table standard it would be like this.

If you would change any type type assignment you should do it during schema by manipulating TIP table by operations.

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

Thanks..I have corrected it.

In function P2011. If I have a work schedule as 7:45 to 15:45 Time id is assigned as 05 insteed of 02

entry in TZP is as below

00.0000  01                     0.0000              0.0000

07.7500  05                     0.0000              1.0000

15.7500  01                     0.0000              0.0000

but when I see other WSR as 19:00 to 3:00 TZP is like

00.0000  01                     0.0000              0.0000

19.0000  02                     0.0000              0.0000

27.0000  01                     0.0000              0.0000

43.0000  09                     0.0000              1.0000

51.0000  01                     0.0000              0.0000

Thanks for helping me. new to Time management.

Help required.

Thanks and regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

I recommend put screenshot of output of DEFTP. What is the clock-in/outs in IT2011?

It's difficult to talk about your case without having access to system. What should have that you don't have it. I mean go to the point to just focus on.

Otherwise please make a document of all output log and send me to have a look at it in detail. If I need more information about your customizing I will ask later.

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Appreciating the help Omid

Screenshot of Infotype 2011

I just check with the security policy of my company then may be I can give you webex or something. so you can help and guide me..

Thanks and regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

By the way, For column P (Processing type for time evaluation)

0 in first P column means there is gap in clock-out/in or a break. To understand gap imagine EE clock-out at 10 and clock-in at 11. Means EE was out of worked(has left company) from 10 to 11 with out any absence record in IT2001 or attendance record in IT2002. 

So if you consider ID column in case P column is 0 you see ID is 02 means this has happened during planned working time. But because of first P column system consider it EE has not worked. So systems consider it as pair type 0 of V_T555Z and assigns K for second P column and 0000 for type type.

Regards,

Omid

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

what do you mean by "night shift it is not calulating properly."? How you would calculate night shift?

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

I will explain my issue completly.

I have two employees

1 have a working time from 7:45 to 15:45. this is completly a day shift. when I am running the Time evaluation for this employee it is working fine

Here we can see Planned time 9 hours. break 0.50 as employee took two break of 0.25 min each.

over time 4 hours as employee worked till 20:45.

Now another employee has a PWT as 19:00 and end at 4:00 AM next day.

His evaluation is as below.

Now for this employee look at break time again this employee has two break one is of 0.33 and another is 0.16. attached screen on time event too.

Hope now I made a point. request your help.

Regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Hi Ankit,

I got the case but what is wrong in this case? What you look for?

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

As I can see in the first screen shot. Total break hours are 0.33+0.16. but if we see the total break hours is showing as 0.16. and rest 0.33 is taking in Short hours.

and when I can see p2011 table TZP

it is not taking first break in to concederation.

Hope I can clarify my Problem

Thanks and regards

Ankit Vasavada

former_member193652
Active Contributor
0 Kudos

Dear Ankit,

have a look Planned and Skeleton time. I think Short time is difference between Planned time and Skeleton time.

As you see in case 1 Planned time and Skeleton time are the same so Short time is zero. To realize why Skeleton time is not the same as Planned time you should run time evaluation for that date and check time types one by one to find it.

As I know Planned time is sum of following time types: 0110, 0120 and 0130

Skeleton time is 0002 + 0005 and time type 0005(Flextime balance) is 0411.

You should consider TR10 to realize how system creates these time types finally.

Regards,

Omid

ankitvasavada
Active Contributor
0 Kudos

Dear Omid

Thansk for the Information. Will Surely check this.

Now the Time types I am using the same for both case one and two. difference is case 1 in a normal shift(Shift start and end is on same day). Case two is night shift (Shift starts today and ends tomorrow).

In Skeleton time I have added breaks too. but it is not taking first break in to account.

Same calculation is working for case 1 and not for case 2.

Regards

Ankit Vasavada

Former Member
0 Kudos

Dear Ankit,

You can use the previous day indicator and also have a look on the below thread.

https://scn.sap.com/thread/2106930

Regards,

Dora

Former Member
0 Kudos

Hi Ankit,

Please check the previous day indicator for the Breaks that are assigned to the Night shift.

Please check it.

Cheers

Venu

ankitvasavada
Active Contributor
0 Kudos

Dear Venu

It was already there.

Regards

Ankit Vasavada