- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2022 10:24 AM
Hi,
I have a flow that will update and close a task (task number 3) automatically based on several conditions. The flow update automatically an asset and then close the task.
I need to check from that flow the states of the previous tasks (tasks number 1 and 2).
If at least one previous task has the state "closed incomplete" or "closed skipped", the flow should change the state of the task 3 to "closed skipped" and not update the asset.
How to check the state of previous tasks from the same RITM from flow i didn't find it ?
Here is my trigger :
Solved! Go to Solution.
- Labels:
-
flow designer

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2022 11:44 AM
Hi Nico,
if those tasks are being generated by the same flow then you can just reference it using the data pills available on the right of the screen.
If these tasks are not part of the current flow then you use the lookup records the action on table sc_task and find the tasks by referencing the requested item and then you can use data pills to get the state values and use it for your purpose.
Regards,
Muhammad
Muhammad

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-05-2022 11:44 AM
Hi Nico,
if those tasks are being generated by the same flow then you can just reference it using the data pills available on the right of the screen.
If these tasks are not part of the current flow then you use the lookup records the action on table sc_task and find the tasks by referencing the requested item and then you can use data pills to get the state values and use it for your purpose.
Regards,
Muhammad
Muhammad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-06-2022 09:43 AM
Hi Muhammad,
Thanks for the reply.
Well i put a lookup records action like you told me and i am able to get therequest item.
But after that, i don't know how to add a condition if state of the task 1 or 2 = closed skipped
Regards,

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-06-2022 01:19 AM
Hi,
By performing a Lookup records action, you can find and iterate through the other tasks.
You have the SCTASK by the trigger, lookup the other SCTASKs by do a lookup on the sc_task table, on all records that have the same parent RITM as the trigger record.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-06-2022 12:01 PM
Hi Olan,
Thanks for the reply. Like i replied to Muhammad, i added the lookup records action but i can't find where to put my condition ( if state of task 1 or 2 = closed skipped).
Regards,