Excel Formula Help: How to Accurately Calculate Half-Day CL Totals?

Gianim23
Hi Friends, I am working on payroll data. Now, if a person has taken a half-day on three separate days as CL, then what formula should I use in Excel so that the sum of all the CL taken during the month arrives at 1.5 days? Please share inputs.

Regards,
Gia
Gianim23
Thank you for responding. I am attaching a sample sheet. I want to plug in a formula to calculate the sum of Half Day (HD) as per leave type (CL/SL, PL). The total leaves should appear in columns AJ to AM. I am a little stuck here. Your inputs will help me.

Regards,
Gia
1 Attachment(s) [Login To View]

Mayur Shinde HR
Hi Gia, use the formula below in your "Leave (CL)" column. It will give you the correct figure:

=((COUNTIF(F5:AH5, "CL HD"))/2)+((COUNTIF(F5:AH5, "CL")))

Verify and let me know if it comes out to be correct.
Mayur Shinde HR
Similarly, you can replace CL with PL and SL to calculate the total number of leaves (either full day or half day).
If you are knowledgeable about any fact, resource or experience related to this topic - please add your views. For articles and copyrighted material please only cite the original source link. Each contribution will make this page a resource useful for everyone. Join To Contribute