<h2>Using the output of "Look Up Records" action inside an custom action</h2><br/><div style="overflow-x:auto"><article><div ><h3 >Description</h3><section><ul style="list-style-position: inside;"><li>how to use the output of "Look Up Records" action in a custom action</li><li>the custom action has an input of type "records" with the reference table of the "Look Up Records"</li><li>So now that it's in the action, now what?</li></ul></section></div><div ><h3 >Instructions</h3><section><ul style="list-style-position: inside;"><li>to obtain for example the sys_id's of all the records brought into the action into an array name "list," do the following:</li><li>add a script step</li><li>attach the action's input to the script step's inputs</li><li>from the script do the following:</li><li>input.<lookRecords_output>.query()<br />while (input.<lookRecords_output>.next() {<br /> list.push(input.<lookRecords_output>.sys_id);<br />}</li><li>We use the query() and next() because the object we're passing into the custom object is GlideRecord</li></ul></section></div></article></div>