- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-21-2023 06:25 AM
In the incident table, in the category updated options (AC, washing machine, TV, microwave oven, fridge), I added one more field called scheduled maintenance. Add it to the options 'Once' and 'Periodically'. If I select periodically, I can see the first field, called repeated interval, and the starting time. If I give input in repeated interval of 10 minutes and the starting date (from the starting date/time, I need to start), every 10 minutes it needs to create an incident.
For this, I have created a scheduled job, selected it periodically, and given a repeated interval of 5 minutes (every 5 minutes), it will execute and check the incidents (if scheduled maintenance is performed periodically, if the condition is true). What would be the script for the execution of scheduled maintenance (periodically)?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-26-2023 06:49 AM
Hi @manumanoj
Sorry for the delay in response. So you want
to match the condition
of Category + scheduled maintenance. and on basis of that you want to run a flow?
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-28-2023 09:00 AM
Hi @manumanoj
I am not good in Flow designer but
Trigger
Repeat every 5 mins
Action
Look up record
On incident table
condition
Category and scheduled
Action
Create Incident
Give a try with this base line.
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-22-2023 05:22 AM
Hi @manumanoj
I am trying to understand
You created a new field scheduled maintenance and under that use are putting 10 mins.
But I think this thing you can achieve via schedule jobs and no need to create new field. You can use flow designer to do all this.
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-26-2023 02:45 AM
Hi Atul
but in the category having options (AC, washing machine, TV, microwave oven, fridge), for example consider that for washing machine need maintenance that every 6 months so i have created scheduled job that updated periodically and repeated interval is 5min(every 5 min scheduled job will execute) check the records if condition is true so in my table field called scheduled maintenance user will selects schedules maintenance that once or periodically
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-26-2023 06:49 AM
Hi @manumanoj
Sorry for the delay in response. So you want
to match the condition
of Category + scheduled maintenance. and on basis of that you want to run a flow?
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-26-2023 08:20 PM
Yes, here is the scheduled job (periodically 5 minutes), so every 5 minutes, the scheduled job executes.
Example: A washing machine needs maintenance every 15 minutes, so in the scheduled maintenance field, selected periodically and repeated intervals of 15 minutes and start time (when to start time) every 15 minutes creates an incident. Basically, if it is script or flow, it is fine.