<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.appian.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>KB-2050 Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load</link><description /><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>KB-2050 Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load</link><pubDate>Tue, 07 Jan 2020 01:47:20 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Parmida Borhani</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Current Revision posted to Appian Knowledge Base by Parmida Borhani on 1/7/2020 1:47:20 AM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing an expression or rule in a script task,&amp;nbsp;and the expression&amp;nbsp;uses the&amp;nbsp;&lt;code&gt;load()&lt;/code&gt;&amp;nbsp;function, users observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior can occur if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is expected behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Upgrade to Appian 19.2 or later and use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in&amp;nbsp;the &lt;a href="https://docs.appian.com/suite/help/latest/Updating_Expressions_to_Use_a_localVariables.html" rel="noopener noreferrer" target="_blank"&gt;documentation&lt;/a&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to&amp;nbsp;all versions of Appian.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;January 2020&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: load function, local variables, script task, application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/9</link><pubDate>Mon, 06 Jan 2020 22:13:45 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Tom Ryan</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 9 posted to Appian Knowledge Base by Tom Ryan on 1/6/2020 10:13:45 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing an expression or rule in a script task,&amp;nbsp;and the expression&amp;nbsp;uses the&amp;nbsp;&lt;code&gt;load()&lt;/code&gt;&amp;nbsp;function, users observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior can occur if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is expected behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Upgrade to Appian 19.2+ and use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in&amp;nbsp;the &lt;a href="https://docs.appian.com/suite/help/latest/Updating_Expressions_to_Use_a_localVariables.html"&gt;documentation&lt;/a&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to&amp;nbsp;all versions of Appian.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;January 2020&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: load function, local variables, script task, application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/8</link><pubDate>Mon, 06 Jan 2020 21:44:15 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 8 posted to Appian Knowledge Base by Nicholas Van Dyke on 1/6/2020 9:44:15 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing an expression or rule in a script task,&amp;nbsp;and the expression&amp;nbsp;uses the&amp;nbsp;&lt;code&gt;load()&lt;/code&gt;&amp;nbsp;function, users observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior can occur if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Upgrade to Appian 19.2+ and use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in&amp;nbsp;the &lt;a href="https://docs.appian.com/suite/help/latest/Updating_Expressions_to_Use_a_localVariables.html"&gt;documentation&lt;/a&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to&amp;nbsp;all versions of Appian.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;January 2020&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: load function, local variables, script task, application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/7</link><pubDate>Mon, 30 Dec 2019 21:30:30 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 7 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/30/2019 9:30:30 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing an expression or rule in a script task,&amp;nbsp;and the expression&amp;nbsp;uses the&amp;nbsp;&lt;code&gt;load()&lt;/code&gt;&amp;nbsp;function, users observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior can occur if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in&amp;nbsp;the &lt;a href="https://docs.appian.com/suite/help/latest/Updating_Expressions_to_Use_a_localVariables.html"&gt;documentation&lt;/a&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: load function, local variables, script task, application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/6</link><pubDate>Mon, 30 Dec 2019 20:14:28 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 6 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/30/2019 8:14:28 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing a script task that uses the&amp;nbsp;&lt;code&gt;load()&lt;/code&gt;&amp;nbsp;function, users observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior can occur if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in&amp;nbsp;the &lt;a href="https://docs.appian.com/suite/help/latest/Updating_Expressions_to_Use_a_localVariables.html"&gt;documentation&lt;/a&gt;.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: load function, local variables, script task, application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/5</link><pubDate>Fri, 06 Dec 2019 22:09:53 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 5 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/6/2019 10:09:53 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing a script task that uses &lt;code&gt;load()&lt;/code&gt;, users may&amp;nbsp;observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior sometimes occurs if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in&amp;nbsp;this documentation:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;a class="external-link" title="Follow link" href="https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html" rel="nofollow"&gt;https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/4</link><pubDate>Fri, 06 Dec 2019 21:59:40 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 4 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/6/2019 9:59:40 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing a script task that uses &lt;code&gt;load()&lt;/code&gt;, users may&amp;nbsp;observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior sometimes occurs if a rule uses the &lt;code&gt;load()&lt;/code&gt; function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use &lt;code&gt;a!localVariables()&lt;/code&gt; instead of &lt;code&gt;load()&lt;/code&gt;, as&amp;nbsp;described in the documentation below:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;a class="external-link" title="Follow link" href="https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html" rel="nofollow"&gt;https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/3</link><pubDate>Fri, 06 Dec 2019 21:52:11 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 3 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/6/2019 9:52:11 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing a script task that uses load(), users may&amp;nbsp;observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior sometimes occurs if a rule uses the load() function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use a!localVariables() instead of load(), as&amp;nbsp;described in the documentation below:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;a class="external-link" title="Follow link" href="https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html" rel="nofollow"&gt;https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/2</link><pubDate>Fri, 06 Dec 2019 21:50:33 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 2 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/6/2019 9:50:33 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing a script task that uses load(), users may&amp;nbsp;observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior sometimes occurs if a rule uses the load() function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use a!localVariables() instead of load(), as&amp;nbsp;described in this documentation:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;a class="external-link" title="Follow link" href="https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html" rel="nofollow"&gt;https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: application design&lt;/div&gt;
</description></item><item><title>DRAFT KB-XXXX Script task outputs are the same despite different inputs when using load()</title><link>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load/revision/1</link><pubDate>Fri, 06 Dec 2019 21:50:00 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:91d11f25-54da-4d2e-8841-01ffba5bfc4b</guid><dc:creator>Nicholas Van Dyke</dc:creator><comments>https://community.appian.com/support/w/kb/1623/kb-2050-script-task-outputs-are-the-same-despite-different-inputs-when-using-load#comments</comments><description>Revision 1 posted to Appian Knowledge Base by Nicholas Van Dyke on 12/6/2019 9:50:00 PM&lt;br /&gt;
&lt;h2&gt;&lt;span&gt;Symptoms&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;When&amp;nbsp;executing a script task that uses load(), users may&amp;nbsp;observe that calling the same rule results in&amp;nbsp;the same output despite different inputs.&amp;nbsp;This behavior sometimes occurs if a rule uses the load() function to store the input in a local variable with the same name and store the output in a process variable.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Cause&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This is intended behavior based on how Appian handles context within a script task.&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Action&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;Use a!localVariables() instead of load(), as&amp;nbsp;described in this documentation:&amp;nbsp;&lt;a class="external-link" title="Follow link" href="https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html" rel="nofollow"&gt;https://docs.appian.com/suite/help/19.2/Updating_Expressions_to_Use_a_localVariables.html&lt;/a&gt;&lt;/span&gt;&lt;/p&gt;
&lt;h2&gt;&lt;span&gt;Affected Versions&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;&lt;span&gt;This article applies to Appian 19.2 and later.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Last Reviewed:&amp;nbsp;December 2019&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;

&lt;div style="font-size: 90%;"&gt;Tags: application design&lt;/div&gt;
</description></item></channel></rss>