โ11-14-2024 03:29 PM
hello ๐,
I just wanted to ask if anyone has any recommendations for a Recipe.
I'm trying to get the number of business days between two dates. The additional challenge is also to exclude holidays.
Do you have any tips? much appreciated.
โ11-15-2024 09:19 AM
To calculate the number of business days between two dates while excluding holidays, you can build a Workato recipe using a combination of triggers and actions.
Here's a simple pseudocode for the logic:
business_days_count = 0
(start_date..end_date).each do |date|
unless date.saturday? || date.sunday? || holidays.include?(date)
business_days_count += 1
end
end