Hello,
I have an airtable app that supports our HR and Finance teams. As part of the build, I am looking to reference the employee ‘start date’ and ‘end date’ to determine how many days, or workdays that employee worked in a specified month (assume each month starts on the 1st and ends on the last day 30/31)
Example fields:
Start date: 01-10-25
End date: 01-25-25
Month Start: 01-01-25
Month End: 01-31-25
The month start and ends fields could be done without referencing the fields if needed and handled within the calc using datetime parse/datetimeformat or the like.
In many examples the end date of the employee will be after the month end but have kept the duration short for this example.
In theory, a simple formula like the below should work, but I’ve tried so many different options of doing this and the formulas keep returning a 0 or error. The fields above are all calculated as date fields.
WORKDAY_DIFF(
MAX({Month Start}, {Start date}),
MIN({Month End}, {End date})
)
I’d expect a working formula to return me a number such as 16 days, or 11 workdays.
This started as part of a larger formula and the rest has been solved but this is the last part giving me trouble!
Anyone have any tips for why this isn’t working or other suggestions for other methods to try.
After my known formulas weren’t working I also tried many AI generated suggestions and none are working.
Thank you!