<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Check State of previous tasks in flow in ServiceNow AI Platform forum</title>
    <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188786#M145175</link>
    <description>&lt;P&gt;Hi Nico,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;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.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;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.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Muhammad&lt;/P&gt;</description>
    <pubDate>Mon, 05 Sep 2022 18:44:16 GMT</pubDate>
    <dc:creator>MrMuhammad</dc:creator>
    <dc:date>2022-09-05T18:44:16Z</dc:date>
    <item>
      <title>Check State of previous tasks in flow</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188785#M145174</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;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.&lt;/P&gt;
&lt;P&gt;I need to check from that flow the states of the previous tasks (tasks number 1 and 2).&lt;/P&gt;
&lt;P&gt;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.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How to check the state of previous tasks from the same RITM from flow&amp;nbsp; i didn't find it ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is my trigger :&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="find_real_file.png"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/117222i944F5BE92AF43E98/image-size/large?v=v2&amp;amp;px=999" role="button" title="find_real_file.png" alt="find_real_file.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Sep 2022 17:24:29 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188785#M145174</guid>
      <dc:creator>Nico12</dc:creator>
      <dc:date>2022-09-05T17:24:29Z</dc:date>
    </item>
    <item>
      <title>Re: Check State of previous tasks in flow</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188786#M145175</link>
      <description>&lt;P&gt;Hi Nico,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;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.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;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.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Muhammad&lt;/P&gt;</description>
      <pubDate>Mon, 05 Sep 2022 18:44:16 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188786#M145175</guid>
      <dc:creator>MrMuhammad</dc:creator>
      <dc:date>2022-09-05T18:44:16Z</dc:date>
    </item>
    <item>
      <title>Re: Check State of previous tasks in flow</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188787#M145176</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;By performing a Lookup records action, you can find and iterate through the other tasks.&lt;/P&gt;
&lt;P&gt;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.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Sep 2022 08:19:29 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188787#M145176</guid>
      <dc:creator>OlaN</dc:creator>
      <dc:date>2022-09-06T08:19:29Z</dc:date>
    </item>
    <item>
      <title>Re: Check State of previous tasks in flow</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188788#M145177</link>
      <description>&lt;P&gt;Hi Muhammad,&lt;/P&gt;
&lt;P&gt;Thanks for the reply.&lt;/P&gt;
&lt;P&gt;Well i put a lookup records action like you told me and i am able to get therequest item.&lt;/P&gt;
&lt;P&gt;But after that, i don't know how to add a condition if state of the task 1 or 2 = closed skipped&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="find_real_file.png"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/117218i058F00A74FC6FB66/image-size/large?v=v2&amp;amp;px=999" role="button" title="find_real_file.png" alt="find_real_file.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;</description>
      <pubDate>Tue, 06 Sep 2022 16:43:18 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188788#M145177</guid>
      <dc:creator>Nico12</dc:creator>
      <dc:date>2022-09-06T16:43:18Z</dc:date>
    </item>
    <item>
      <title>Re: Check State of previous tasks in flow</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188789#M145178</link>
      <description>&lt;P&gt;Hi Olan,&lt;/P&gt;
&lt;P&gt;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).&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;</description>
      <pubDate>Tue, 06 Sep 2022 19:01:49 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188789#M145178</guid>
      <dc:creator>Nico12</dc:creator>
      <dc:date>2022-09-06T19:01:49Z</dc:date>
    </item>
    <item>
      <title>Re: Check State of previous tasks in flow</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188790#M145179</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;Nevermind, i succeed to achieve what i wanted. Thanks for the replies.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Sep 2022 08:35:27 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/check-state-of-previous-tasks-in-flow/m-p/1188790#M145179</guid>
      <dc:creator>Nico12</dc:creator>
      <dc:date>2022-09-08T08:35:27Z</dc:date>
    </item>
  </channel>
</rss>

