cancel
Showing results for 
Search instead for 
Did you mean: 

CATS - Determine target hours.

Former Member
0 Kudos

Hi experts,

We have a scenario in CATS where in we have to subtract the hours reported in IT2002 from the default target hours mentioned on the initial screen- if the hours reported in 2002 are within the working hours for the employee.

I planned to write this logic in the user exit - CATP0001

I see that this conditional logic can be written there and the changed target hours passed to export to reflect accordingly, however I do not understand how to get the default target hours being displayed on the cats screen?

For ex: Lets say we have 7,7,7,7,7,0,0 - default target hours(Monday to Sunday), based on it2002 for an employee I should change this to lets say 5,7,7,7,7,0,0. I do not want to manually calculate the target hours from scratch as it is a combination of IT0007, IT2003 etc and would be redundancy to recalculate it.

In CATP0001 - Is there any chance I get this default 7,7,7,7,7,0,0? and then compute just the reduction and change it?

Or is the default computed after this user exit?
I tried reading (SAPLCATS)CATSD-DAY1 in the debugging mode in the user exit - it does not hold any value yet.

Your inputs on this will be very helpful.

Thanks & Regards,

Gayathri Shanbhag

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Soon after I sent this out - Came accross FM CATS_GET_TARGET_HOURS with which I can get the target hours, using the parameters in the user exit CATP0001.

Issue is now resolved.

Former Member
0 Kudos

Hi Gayathri,

I need to do something similar (change some of the target hours) and continue to display the actual hours "as is".

So, instead of recreating the whole standard logic, I was hoping to find a FM or sub routine to give me the actual target hours and then I was hoping to add my custom logic in the user exit CATP0001 to modify the days as needed.

When I read this thread, I was glad to find a solution. But looks like the FM checks the user exit first. So, I cannot really use this FM in the user exit CATP0001. It would end up like an infinite loop of calls to one another (FM to User Exit and User Exit to FM).

So, I am curious as to how once can achieve this (get the actual target hours and then use custom logic in user exit).

Any inputs or help is highly appreciated.

Thank you!!!

-MM

Answers (0)