Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Adding Monthly accruals

Hi

I would like a field to accumulate/accrue days of 1.67 per month.

Eg. if an employee has 0 days leave, he would accumulate 1.67 days per leave which should accrue each month.

What script would be best in achieving this?

1 Solution

Accepted Solutions
11 Replies
shiveshsingh
Master
Master

Can you elaborate your requirement? Not able to get it.

marcelviegas
Creator II
Creator II

Can you elaborate your requirement? Not able to get it.

Anonymous
Not applicable
Author

If I am an employee with 0 days leave, each month 1.67 days of leave will be added to my Leave Balance.

In order for this to continue adding 1.67 days of leave, I'm not sure what the script should look like?

EG.Leave.PNG

marcelviegas
Creator II
Creator II

how is your source table or script?
Does he get the month or you should get the months automatic?
Do you have how to attach your qvw?

shiveshsingh
Master
Master

Okay, do you have month column?

Or it needs to be created in inline?

Anonymous
Not applicable
Author

I do have a Month column that was created with script. Initially it was dates ranging from 01/01/2018 up until 31/12/2018.

Does that help?

marcelviegas
Creator II
Creator II

follows example, if you attach your structure becomes more accurate.

load employee,count(distinct month_table)*1,6

from Table

where month_table <=month(today())

group by employee;

shiveshsingh
Master
Master

Like this?

Anonymous
Not applicable
Author

100%! Exactly like that and it sums up each month. Thank you Shivesh