Using "State" data pill from closed task to set state of request

Bsublett
Tera Expert

I am trying to set the state of the RITM and REQ to the value of the task state. I have chosen "Update Record" for each and selected the "State" field then chose the state using the data pill from the previously closed task state. I would think that this would update the RITM state but the state stays "Open". Is this not an option in SN?Screenshot 2025-06-16 154523.png

 

1 ACCEPTED SOLUTION

@Bsublett 

that's correct.

you will have to use f(x) inline script for the State field and set the RITM state as per SC Task's state

If your catalog task is closed with any of these (Closed Complete, Closed Incomplete, Close Skipped) then set RITM State as Closed

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

View solution in original post

4 REPLIES 4

anshul_goyal
Kilo Sage

Hello @Bsublett,

In my understanding, it doesn’t work that way. Instead, you can use an If logic action to check whether the Catalog Task is marked as 'Closed Complete'. If it is, use the Update Record action to set the states of both the RITM and the REQ to 'Closed Complete'.

For Ex:

anshul_goyal_0-1750139642906.png


Please mark my solution as helpful and accepted for future reference.

Thanks



Ankur Bawiskar
Tera Patron
Tera Patron

@Bsublett 

if you want to close RITM after catalog task is closed then simply set the State value

Why are you setting the field value using Previous data pill state value?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

I was just going to set it at the same state as task. I found another article that said I would have to transform the 

value from the data pill so I will probably just use IF statements.

@Bsublett 

that's correct.

you will have to use f(x) inline script for the State field and set the RITM state as per SC Task's state

If your catalog task is closed with any of these (Closed Complete, Closed Incomplete, Close Skipped) then set RITM State as Closed

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader