Sub flow Map Return Value to question

Lucky1
Tera Guru

Hello everyone,

 

In a Workflow I see, we are calling another workflow as sub flow.

So, here I see a field, "Map return Value to"

and that field is filled up with value, ret

 

So, can someone explain me what that Map return value to field does here?

My openion:

Is it storing the sub flow's returning value into that field?

 

 

Please help.

 

Regards,

Lucky

1 REPLY 1

Maddysunil
Kilo Sage

@Lucky1 

Yes, your understanding is correct. The "Map Return Value to" field in a ServiceNow workflow allows you to specify where the return value of the subflow should be stored.

In your case, if the "Map Return Value to" field is filled with the value "ret", it means that the return value of the subflow will be stored or assigned to a field named "ret" within the current workflow.

So, when the subflow completes its execution and returns a value, that value will be captured and stored in the "ret" field of the parent workflow. This allows you to use or further process the return value within the parent workflow as needed.

 

Please Mark Correct if this solves your query and also mark 👍Helpful if you find my response worthy based on the impact.

 

Thanks