<?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 Importing data into site table in WSD in Community Central forum</title>
    <link>https://www.servicenow.com/community/community-central-forum/importing-data-into-site-table-in-wsd/m-p/3553452#M7089</link>
    <description>&lt;P&gt;I am importing data into the &lt;STRONG&gt;sn_wsd_core_site&lt;/STRONG&gt; table from an Excel file. The source file contains two columns: &lt;STRONG&gt;Region&lt;/STRONG&gt; and &lt;STRONG&gt;Site&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;During the import, the &lt;STRONG&gt;Site&lt;/STRONG&gt; records are being created/updated successfully, and the site names are visible in the &lt;STRONG&gt;sn_wsd_core_site&lt;/STRONG&gt; table. However, the &lt;STRONG&gt;Region&lt;/STRONG&gt; field is not getting populated.&lt;/P&gt;&lt;P&gt;The &lt;STRONG&gt;Region&lt;/STRONG&gt; field is a reference field that points to the &lt;STRONG&gt;sn_wsd_core_region&lt;/STRONG&gt; table. In the Transform Map, I have mapped the source Region column to the Region reference field and enabled reference field mapping.&lt;/P&gt;&lt;P&gt;Could anyone advise what additional configuration is required to populate the Region reference field correctly during import? Are there any specific settings for reference fields, coalesce fields, or transform scripts that I should check?&lt;/P&gt;&lt;P&gt;Any guidance would be appreciated. Thank you.&lt;/P&gt;</description>
    <pubDate>Wed, 03 Jun 2026 20:13:36 GMT</pubDate>
    <dc:creator>harshacool9</dc:creator>
    <dc:date>2026-06-03T20:13:36Z</dc:date>
    <item>
      <title>Importing data into site table in WSD</title>
      <link>https://www.servicenow.com/community/community-central-forum/importing-data-into-site-table-in-wsd/m-p/3553452#M7089</link>
      <description>&lt;P&gt;I am importing data into the &lt;STRONG&gt;sn_wsd_core_site&lt;/STRONG&gt; table from an Excel file. The source file contains two columns: &lt;STRONG&gt;Region&lt;/STRONG&gt; and &lt;STRONG&gt;Site&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;During the import, the &lt;STRONG&gt;Site&lt;/STRONG&gt; records are being created/updated successfully, and the site names are visible in the &lt;STRONG&gt;sn_wsd_core_site&lt;/STRONG&gt; table. However, the &lt;STRONG&gt;Region&lt;/STRONG&gt; field is not getting populated.&lt;/P&gt;&lt;P&gt;The &lt;STRONG&gt;Region&lt;/STRONG&gt; field is a reference field that points to the &lt;STRONG&gt;sn_wsd_core_region&lt;/STRONG&gt; table. In the Transform Map, I have mapped the source Region column to the Region reference field and enabled reference field mapping.&lt;/P&gt;&lt;P&gt;Could anyone advise what additional configuration is required to populate the Region reference field correctly during import? Are there any specific settings for reference fields, coalesce fields, or transform scripts that I should check?&lt;/P&gt;&lt;P&gt;Any guidance would be appreciated. Thank you.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jun 2026 20:13:36 GMT</pubDate>
      <guid>https://www.servicenow.com/community/community-central-forum/importing-data-into-site-table-in-wsd/m-p/3553452#M7089</guid>
      <dc:creator>harshacool9</dc:creator>
      <dc:date>2026-06-03T20:13:36Z</dc:date>
    </item>
    <item>
      <title>Re: Importing data into site table in WSD</title>
      <link>https://www.servicenow.com/community/community-central-forum/importing-data-into-site-table-in-wsd/m-p/3553517#M7090</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/1063449"&gt;@harshacool9&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. By default, when you map a source string to a reference field, ServiceNow tries to match that string against the &lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;sn_wsd_core_region&amp;nbsp;&lt;/STRONG&gt;table's &lt;STRONG&gt;Display Value&lt;/STRONG&gt; field.&lt;/P&gt;&lt;P&gt;If your source Excel column contains region data that &lt;STRONG&gt;doesn't match the display column exactly&lt;/STRONG&gt; , the mapping fails and leaves the field blank.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Fix:&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;UL class=""&gt;&lt;LI&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;Fix&lt;/STRONG&gt;: Write a quick Field map script/&amp;nbsp;&lt;STRONG&gt;Before Transform Script&lt;/STRONG&gt; on your transform map to automatically trim spaces and manually look up the reference record.&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;(&lt;/SPAN&gt;&lt;SPAN class=""&gt;function&lt;/SPAN&gt;&lt;SPAN class=""&gt; runTransformScript(source, map, log, &lt;/SPAN&gt;&lt;SPAN class=""&gt;target&lt;/SPAN&gt; &lt;SPAN class=""&gt;/*undefined onStart*/&lt;/SPAN&gt;&lt;SPAN class=""&gt; ) {
    &lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; sourceRegion = source.u_region.toString().trim(); &lt;/SPAN&gt;&lt;SPAN class=""&gt;// Replace u_region with your exact source staging column&lt;/SPAN&gt;
    
    &lt;SPAN class=""&gt;var&lt;/SPAN&gt;&lt;SPAN class=""&gt; regGr = &lt;/SPAN&gt;&lt;SPAN class=""&gt;new&lt;/SPAN&gt;&lt;SPAN class=""&gt; GlideRecord(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'sn_wsd_core_region'&lt;/SPAN&gt;&lt;SPAN class=""&gt;); &lt;/SPAN&gt;&lt;SPAN class=""&gt;// WSD region table&lt;/SPAN&gt;
    &lt;SPAN class=""&gt;if&lt;/SPAN&gt;&lt;SPAN class=""&gt; (regGr.&lt;/SPAN&gt;&lt;SPAN class=""&gt;get&lt;/SPAN&gt;&lt;SPAN class=""&gt;(&lt;/SPAN&gt;&lt;SPAN class=""&gt;'name'&lt;/SPAN&gt;&lt;SPAN class=""&gt;, sourceRegion)) {
        &lt;/SPAN&gt;&lt;SPAN class=""&gt;target&lt;/SPAN&gt;&lt;SPAN class=""&gt;.region = regGr.getUniqueValue();
    }
})(source, map, log, &lt;/SPAN&gt;&lt;SPAN class=""&gt;target&lt;/SPAN&gt;&lt;SPAN class=""&gt;);&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2.&amp;nbsp;If the Region name in your Excel sheet does not exist yet in your ServiceNow instance, the Transform Map handles it based on its &lt;STRONG&gt;Choice action&lt;/STRONG&gt; rule.&lt;/P&gt;&lt;P&gt;If it is set to &lt;STRONG&gt;Ignore&lt;/STRONG&gt;, ServiceNow leaves the field blank instead of creating the new Region.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As Region is foundational data, customer generally not allow to add garbage data instead of Approved one.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Note:&lt;/STRONG&gt;&amp;nbsp;Make choice action of the field map's&amp;nbsp;&lt;STRONG&gt;Choice action as&amp;nbsp;&lt;/STRONG&gt;&lt;STRONG&gt;Create&lt;/STRONG&gt; if you want ServiceNow to automatically create new region records when it encounters unmatched text.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 Jun 2026 04:45:51 GMT</pubDate>
      <guid>https://www.servicenow.com/community/community-central-forum/importing-data-into-site-table-in-wsd/m-p/3553517#M7090</guid>
      <dc:creator>Tanushree Maiti</dc:creator>
      <dc:date>2026-06-04T04:45:51Z</dc:date>
    </item>
  </channel>
</rss>

