- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-19-2022 02:22 PM
Hello,
I have a requirement to find a solution that is either OOB or close to OOB to calculate the Date Difference between Business Days and Calendar Days. Business Days are defined as Mon-Friday and Calendar Days would be 7 days a week. We are going to create a separate field on our table that specifies whether our merchants work in Business Days or Calendar Days.
Does ServiceNow offer an easy way of doing this without have to create Scripts?
Thanks!
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-19-2022 06:44 PM
Hi mballinger,
Calendars can be defined in Business Calendar. However, a script is required to check if the date is in a business calendar.
Example of script to validate date with business calendar is provided in the following thread. A script consists of creating GlideSchedule and using .isInSchedule(<date to validate>).

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-19-2022 03:16 PM
Hi,
There is not a way to do this without a script.
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-02-2022 06:56 AM
Hi,
I'm glad you found a correct answer that worked for you.
My apologies, it wasn't clear you were looking for other suggestions, but more so simply asking if it was possible without scripting, to which I replied above that it was not.
Take care! 🙂
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-19-2022 03:56 PM
Hi,
Just curious to understand what is the requirement here.
Would it be acceptable to create 2 SLA definitions, one that will fire for merchants working on Business days and one firing for merchants working on Calendar days.
The sla_task created will then contain the good due date for the work.
Regards.
JP
JP

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-19-2022 06:44 PM
Hi mballinger,
Calendars can be defined in Business Calendar. However, a script is required to check if the date is in a business calendar.
Example of script to validate date with business calendar is provided in the following thread. A script consists of creating GlideSchedule and using .isInSchedule(<date to validate>).