<?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 Transform map - User defined variable for all rows in ServiceNow AI Platform forum</title>
    <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/transform-map-user-defined-variable-for-all-rows/m-p/3394911#M205362</link>
    <description>&lt;P&gt;HI team&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to read a System property from a Transform map and store it in a user defined variable&amp;nbsp;&lt;/P&gt;&lt;P&gt;ex - &lt;STRONG&gt;allowedlistsysprop&lt;/STRONG&gt;&amp;nbsp;and have the variable available for all row transformations&lt;/P&gt;&lt;P&gt;Basically i have a list of allowed matches in a system property and would like to do string match something like below for each row&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;if (source.myfield1.indexOf(allowedlistsysprop) != -1)
{
//do something
}&lt;/LI-CODE&gt;&lt;P&gt;I would read the property only once and can define the variable in an onStart script .But not sure how to properly define it in onStart script and&amp;nbsp; access it in each of the OnBefore script and more important make sure the variable doesn't leak into any other process .&lt;/P&gt;&lt;P&gt;i am reading some references setting it as a global variable using onStart script . But how do i make sure the variable doesnt spam other processing .Appreciate any guidance around this&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;Lakshmi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 01 Oct 2025 02:16:42 GMT</pubDate>
    <dc:creator>lakshmin</dc:creator>
    <dc:date>2025-10-01T02:16:42Z</dc:date>
    <item>
      <title>Transform map - User defined variable for all rows</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/transform-map-user-defined-variable-for-all-rows/m-p/3394911#M205362</link>
      <description>&lt;P&gt;HI team&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would like to read a System property from a Transform map and store it in a user defined variable&amp;nbsp;&lt;/P&gt;&lt;P&gt;ex - &lt;STRONG&gt;allowedlistsysprop&lt;/STRONG&gt;&amp;nbsp;and have the variable available for all row transformations&lt;/P&gt;&lt;P&gt;Basically i have a list of allowed matches in a system property and would like to do string match something like below for each row&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;if (source.myfield1.indexOf(allowedlistsysprop) != -1)
{
//do something
}&lt;/LI-CODE&gt;&lt;P&gt;I would read the property only once and can define the variable in an onStart script .But not sure how to properly define it in onStart script and&amp;nbsp; access it in each of the OnBefore script and more important make sure the variable doesn't leak into any other process .&lt;/P&gt;&lt;P&gt;i am reading some references setting it as a global variable using onStart script . But how do i make sure the variable doesnt spam other processing .Appreciate any guidance around this&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;Lakshmi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 01 Oct 2025 02:16:42 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/transform-map-user-defined-variable-for-all-rows/m-p/3394911#M205362</guid>
      <dc:creator>lakshmin</dc:creator>
      <dc:date>2025-10-01T02:16:42Z</dc:date>
    </item>
    <item>
      <title>Re: Transform map - User defined variable for all rows</title>
      <link>https://www.servicenow.com/community/servicenow-ai-platform-forum/transform-map-user-defined-variable-for-all-rows/m-p/3396928#M205391</link>
      <description>&lt;P&gt;Reference from &lt;A href="https://www.servicenow.com/community/developer-forum/setting-and-reusing-variables-during-import-transform/m-p/2169577" target="_self"&gt;post&lt;/A&gt;&amp;nbsp;by MGanon , usins a this.variablename in the onStart script makes it available to all script in same transform map&lt;/P&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Fri, 03 Oct 2025 09:59:24 GMT</pubDate>
      <guid>https://www.servicenow.com/community/servicenow-ai-platform-forum/transform-map-user-defined-variable-for-all-rows/m-p/3396928#M205391</guid>
      <dc:creator>lakshmin</dc:creator>
      <dc:date>2025-10-03T09:59:24Z</dc:date>
    </item>
  </channel>
</rss>

