cancel
Showing results for 
Search instead for 
Did you mean: 

How to maintain IT 0041 for leave?

Former Member
0 Kudos

Hello Experts,

I have requirement while taking leave AWL and Suspension the date should get reflected in IT 0041.

Now I would like to know is it possible to do through configuration or I have to maintain IT 0041 manually?

Kindly reply.

Thank You

Manjiri

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Manjiri,

If that is your requirement then why don't you maintain a dynamic action on IT 2001? Everytime IT 2001 is saved with absence type AWL or suspension you can save the start date of leave in IT 0041.

But do you like maintain one record for IT 0041 for entire span of employee or a record per year for IT 0041? If the answer is per year then dynamic action will be simple or else you will have to create a routine and then call it in your program.

Check the feasibility of dynamic action and do let us know if you face problems.

cheers

Ajay

Former Member
0 Kudos

Hi!

Thank for your reply.

I will be happy if your brife on how to do it.

Thank you

Former Member
0 Kudos

Manjiri,

You did not answer my question of how you maintain IT 0041 records?

Also, IT 0041 will have 12 maximum date types which you can maintain. Do you mean to say that he will apply AWL or suspension only once? or he may apply it several times in a year?

Please answers these question so that experts can understand the requirement better.

cheers

Ajay

Binu
Participant
0 Kudos

Hi Ajay,

Please ref the condition mentioned below:

Condition for creating new entry for IT 0041 (for generating Half pay leave):

Input data:

1. Enter the Personnel Number

2. Enter Infotype 2001

3. Enter Sub Type SUSP or AWL( Suspension / Absense witout leave)

4. Enter the date

5. Save the record

out put data:

1. Based on no of AWL + SUSP record in IT 0041 will be created.

2. No of days in AWL + SUSP will be added in the new record of IT 0041.

3. The record created in IT 0041 will be used in creating Half pay Leave

Our client considers Susp and AWL as punishments and any instance of records of Susp or AWL will hamper the accumulation of HPL for an employee.

The leave management program here Z developed. So the program logic is , if an employee applies for HPL,the program has to refer 0041 before showing his HPL accmulation till date.

Employees here get HPL quota of 20 leaves per year.

The entries of AWL and SUSP in 0041 for this yearwill effect for HPL generation for the next year only.

The above logic was working fine before. I also see that Dynamic actions have been set up for 2001 to record data into 0041.

For some reason its not working now.

Please suggest.

Regards,

Binu Philipose

Former Member
0 Kudos

Hi,

I think I got the most of the logic but I didnt understand the output part. If you dont mind can you explain it with an example

1.	Enter the Personnel Number
2.	Enter Infotype 2001
3.	Enter Sub Type SUSP or AWL( Suspension / Absense witout leave)
4.	Enter the date
5.	Save the record 

out put data:

1.	Based on no of AWL + SUSP record in IT 0041 will be created.
2.	No of days in AWL + SUSP will be added in the new record of IT 0041.
3.	The record created in IT 0041 will be used in creating Half pay Leave

specially the point 2 in output which says "No of days in AWL or SUSP will be added in new record". I T 0041 will only hold date type and dates for it.

If you clear my doubt i can look into it.

cheers

Ajay

Binu
Participant
0 Kudos

Hi,

Since AWL and SUSP are considered as punishments, there is a possibility of several records of the same being entered in IT 2001 for an employee in an year.

Hence, as per the 2nd output option, each entry of the above should add new entries to IT 0041.

Let me know if you need more info...

Regards,

Binu

Former Member
0 Kudos

Hi Binu,

See I need a example like

In IT 0041 we have a record from validity 01.01.2010 to 31.12.9999 with

date type 01(hire date) - 01.01.2010

date type 02 (retire date) - 01.01.2030

Now you enter AWL in IT 2001 from say 01.03.2010 to 05.03.2010 (5 days). Then what do you want to store in IT 0041? Start date of IT 2001 subtype AWL record?

IT 0041 can hold maximum of 12 date types what if cases of AWL and SUSP are more than 12? How will you accomodate them?

Ajay

Binu
Participant
0 Kudos

Hi Ajay,

Your assumption is correct. We would like 0041 to create a record of 01.03.2010 to 05.03.2010 (5 days) AWL awarded to the employee from IT 2001.

Here 0041 will only record entries from 2001 and no where else. N if an employee gets more than 2 to 3 punishments in an year then correction actions are taken against him.

Where can i chk the subtypes created for 2001?

Also i see entries for 2001 with ref to 0041 in Dynamic action.... How can i figure out wht has gone wrong?

Below mentioned are the couple of entries i see in Dynamic action? IMG says 210 here is a subtype of 2001.

I need to chk wht subtype is it?? So ver can i chk it?? N how to figure out how the dynamic action is configures??

2001 210 2 2 F CHECK_ABS_PERIOD(HBRDYNMS)

2001 210 2 3 P RP50D-FLAG1='Y'

2001 210 2 4 I MOD,41,,,,(RP50D-DATE1)/D

2001 210 2 5 I INS,41,,,(RP50D-DATE2),(RP50D-DATE2)/D

2001 210 2 6 F LIMIT_PF(HBRDYNMS)

2001 210 2 7 F GET_NEW_DATES(HBRDYNMS)

2001 210 2 8 W P0041-DAR01=RP50D-FIELD1(2)

2001 210 2 9 W P0041-DAT01=RP50D-DATE1

2001 210 2 10 F GET_NEW_DATES(HBRDYNMS)

2001 210 2 11 W P0041-DAR02=RP50D-FIELD1(2)

2001 210 2 12 W P0041-DAT02=RP50D-DATE1

2001 210 2 13 F GET_NEW_DATES(HBRDYNMS)

2001 210 2 14 W P0041-DAR03=RP50D-FIELD1(2)

2001 210 2 15 W P0041-DAT03=RP50D-DATE1

2001 210 2 16 F GET_NEW_DATES(HBRDYNMS)

I know this is getting challenging for u....

Cheers,

Binu

Binu
Participant
0 Kudos

Hey,

N like you said...

In IT 0041 we have a record from validity 01.01.2010 to 31.12.9999 with

date type 01(hire date) - 01.01.2010

date type 02 (retire date) - 01.01.2030

Now you enter AWL in IT 2001 from say 01.03.2010 to 05.03.2010 (5 days). Then what do you want to store in IT 0041? Start date of IT 2001 subtype AWL record?

IT 0041 can hold maximum of 12 date types what if cases of AWL and SUSP are more than 12? How will you accomodate them?

As mentioned above, 12 cases for a year Or for date type 01 and date type 02 as mentioned above....

Former Member
0 Kudos

Hi Binu,

Where can i chk the subtypes created for 2001?

You can check the absence subtype in view V_T554S from tcode SM30.

Please check if the subtype here refers to AWL or SUSP.

I will try to decode the logic of your dynamic action till then.

cheers

Ajay

Binu
Participant
0 Kudos

Thanks Ajay,

Well there 92 lines of dynamic action logic for the subtype 210... if you want i can send you the same....

Former Member
0 Kudos

HI Binu if 210 subtype refers to either AWL or SUSP then he is the explanation. When a record in IT 2001 with subtype 210 is created( The function code 2 in the 3rd column) then

IT subty FC line operation code

2001 210 2 2 F CHECK_ABS_PERIOD(HBRDYNMS) - Call routine CHECK_ABS_PERIOD in program HBRDYNMS

2001 210 2 3 P RP50D-FLAG1='Y' - If routine returns flag1 as Y then

2001 210 2 4 I MOD,41,,,,(RP50D-DATE1)/D - Modify IT0041(full value of 0041 should be maintained not 41)

2001 210 2 5 I INS,41,,,(RP50D-DATE2),(RP50D-DATE2)/D - Create IT0041 in background

2001 210 2 6 F LIMIT_PF(HBRDYNMS)

2001 210 2 7 F GET_NEW_DATES(HBRDYNMS)

2001 210 2 8 W P0041-DAR01=RP50D-FIELD1(2)

2001 210 2 9 W P0041-DAT01=RP50D-DATE1

2001 210 2 10 F GET_NEW_DATES(HBRDYNMS)

2001 210 2 11 W P0041-DAR02=RP50D-FIELD1(2)

2001 210 2 12 W P0041-DAT02=RP50D-DATE1

2001 210 2 13 F GET_NEW_DATES(HBRDYNMS)

2001 210 2 14 W P0041-DAR03=RP50D-FIELD1(2)

2001 210 2 15 W P0041-DAT03=RP50D-DATE1

2001 210 2 16 F GET_NEW_DATES(HBRDYNMS)

After line 5 what you are trying to do is call routines like LIMIT_PF, GET_NEW_DATES etc from program HBRDYNMS. The return values ( RF50D-XXXX) of these routines are then used as default for fields on IT 0041.

Get hold of an ABAPer and then he will be able to explain better as to what the routines return whenever they are called using F and syntax ROUTINE(PROGRAM). The structure RP50D acts as interface between Dynamic action and Program HBRDYNMS. Note that HBRDYNMS is a standard program.

cheers

Ajay

Binu
Participant
0 Kudos

Hey Ajay,

Table V_T554Sonly shows the subtypes created in the system however it doesnot show what subtype 210 in Dynamic action stands for..

I would like to know that....

If its exist then there definitely has to be a table where it is maintained... any idea on how to figure it out????

And i feel the dynamic action logic for 2001 in here iis correct however its not functioning for some reason... i need to know how i can activate it again???

Can u tell me which part line in dynamic action steps triggers the action....

Regards,

Binu

Former Member
0 Kudos

Hi Binu,

Table V_T554Sonly shows the subtypes created in the system however it doesnot show what subtype 210 in Dynamic action stands for..

Absences are created in this view. There should be a text which will identify each absence type. Check if 210 corresponds to SUSP or AWL

And i feel the dynamic action logic for 2001 in here iis correct however its not functioning for some reason... i need to know how i can activate it again??? 

Can u tell me which part line in dynamic action steps triggers the action....

Let me paste some links to you which might be useful to you to understnad dynamic actions better. Go through this links also accompany your ABAPer with you.

http://www.slideshare.net/meyersh/dynamicactionsonsteroids

http://wiki.sdn.sap.com/wiki/display/ERPHCM/HowtoCreateaDynamic+action

In your dynamic action there are letter like

F, I , P etc they all mean something. Go through the link and you will be able to figure it out.

cheers

Ajay

former_member47879
Active Contributor
0 Kudos

You can try this scenario using dynamic actions