Flow Designer Sets Status to 107 or 157 not 'Closed'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2023 09:01 AM
I've created a flow, so when a Problem is closed, it will auto closed any incidents that are linked to the Problem, by looking at the 'First reported by' field. In testing, the correct incident is identified, and the state updated, but it updates to either 107 or 157, depending on the 'Closed' option selected in the Action. But it never sets to 'Closed'. How can I get the state to update correctly?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2023 09:12 AM - edited ‎11-08-2023 09:13 AM
@Ben28 Since you are setting the state on the task record, it seems that an incorrect Closed state is being set on the state field of your incident record. Instead of performing the update on the Task record, you should do it on the incident record, this way only incident related state would be shown and you will have correct state populated on incident form.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2023 09:58 AM
I tried to set the table as [Incident], however when I change the table, it resets the Record Pill Picker. When selecting the Pil Picker to pick the 'First Reported By' it defaults to Task table, so I think it has to be Task table?
Apparently there is an OoTB Business Rule, that can be enabled. However I've tried enabling it, and it doesn't work in testing, so far.
https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0743796
https://<instance-name>.service-now.com/nav_to.do?uri=sys_script.do?sys_id=1c263220c6112275006955271bf6ba4f

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2023 06:00 PM
If the pill picker defaults to Task table, then your best bet would to try with different Closed states available in the drop down and find the one meant for Incident.
Following filter shows choices available when filtered with label 'Closed' on state field of Task.
The one you need to choose is with value 7 in your flow. Since the state drop down in flow doesn't show the value, the only option you are left with is to choose each one of them and test until you find the right one.
Hope this helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-08-2023 08:34 PM - edited ‎11-08-2023 08:35 PM
@Ben28 going off of sandeep's post, instead of checking each on you could change the label, find it in flow designer and then change it back