Async business rule to fetch the date in which state is updated as fix in progress
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-06-2025 06:36 AM
Hi,
I need to write a async business rule to fetch the date dynamically in which the problem state is changed to fix in progress. Can anyone give me the base idea?
TIA
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-06-2025 08:05 AM
current.u_fix_datetime is?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-06-2025 08:06 AM
new GlideDateTime is a object we are creating.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-06-2025 08:13 AM
since you don't want to query audit table, you will have to create a new date/time field to hold the exact time when state got moved to Fix in progress
u_fix_datetime -> new date/time field on that table
When your BR runs when State moves to Fix in progress new GlideDateTime() will populate the current date/time when that state got changed
In this way you can know later on the exact date/time value when state got moved.
I believe I provided enough help and guidance for your question. Based on your developer skills you can enhance the script.
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-06-2025 07:00 PM
Hope you are doing good.
Did my reply answer your question?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-06-2025 07:19 PM
Hi @Ankur Bawiskar . Yes, your answer did help me understand how the date is stored. But I am stuck in functionality requirement. My requirement is, I have to take this date value in Scheduled Job. Any suggestion for this?