<?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>topic Re: Autopopulate a field based on previous question in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689304#M65597</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You’re very close. The issue is that your &lt;STRONG&gt;pulldata() syntax is incorrect for XLSForm&lt;/STRONG&gt;. In pulldata(), the &lt;STRONG&gt;second argument must be the column you want returned&lt;/STRONG&gt;, not "@choice".&lt;/P&gt;&lt;H3&gt;Correct Syntax&lt;/H3&gt;&lt;P&gt;Use:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;pulldata('region','region','name',${jurisdiction})&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;Explanation&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;pulldata('file','column_to_return in the csv','lookup_column in the csv','lookup_value')&lt;/P&gt;&lt;P&gt;So in your case:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;file&lt;/STRONG&gt; → region (the name of the CSV file without .csv)&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;column_to_return&lt;/STRONG&gt; → region&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;lookup_column&lt;/STRONG&gt; → name&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;lookup_value&lt;/STRONG&gt; → ${jurisdiction}&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Meaning:&amp;nbsp;&lt;SPAN&gt;Look in the &lt;/SPAN&gt;&lt;STRONG&gt;region.csv&lt;/STRONG&gt;&lt;SPAN&gt; file, find the row where &lt;/SPAN&gt;&lt;STRONG&gt;name = selected jurisdiction&lt;/STRONG&gt;&lt;SPAN&gt;, and return the &lt;/SPAN&gt;&lt;STRONG&gt;region&lt;/STRONG&gt;&lt;SPAN&gt; value.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 09 Mar 2026 10:04:24 GMT</pubDate>
    <dc:creator>hmorgan</dc:creator>
    <dc:date>2026-03-09T10:04:24Z</dc:date>
    <item>
      <title>Autopopulate a field based on previous question</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689288#M65594</link>
      <description>&lt;P&gt;I have a select_one question asking for County. Based on that selection, I want to calculate/assign a Region. I want that Region to be auto-populated based on the County selection.&lt;/P&gt;&lt;P&gt;what I currently have in the calculation cell:&amp;nbsp;pulldata("@choice",'region','name',${jurisdiction})&lt;/P&gt;&lt;P&gt;Survey design and results:&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="region.png" style="width: 999px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/149522iC8D7B4A77F71BBD2/image-size/large?v=v2&amp;amp;px=999" role="button" title="region.png" alt="region.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;See what I am doing wrong?&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/16421"&gt;@DougBrowning&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/363906"&gt;@jcarlson&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Mar 2026 02:32:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689288#M65594</guid>
      <dc:creator>GeoWorld13</dc:creator>
      <dc:date>2026-03-09T02:32:20Z</dc:date>
    </item>
    <item>
      <title>Re: Autopopulate a field based on previous question</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689304#M65597</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You’re very close. The issue is that your &lt;STRONG&gt;pulldata() syntax is incorrect for XLSForm&lt;/STRONG&gt;. In pulldata(), the &lt;STRONG&gt;second argument must be the column you want returned&lt;/STRONG&gt;, not "@choice".&lt;/P&gt;&lt;H3&gt;Correct Syntax&lt;/H3&gt;&lt;P&gt;Use:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;pulldata('region','region','name',${jurisdiction})&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;Explanation&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;pulldata('file','column_to_return in the csv','lookup_column in the csv','lookup_value')&lt;/P&gt;&lt;P&gt;So in your case:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;file&lt;/STRONG&gt; → region (the name of the CSV file without .csv)&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;column_to_return&lt;/STRONG&gt; → region&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;lookup_column&lt;/STRONG&gt; → name&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;lookup_value&lt;/STRONG&gt; → ${jurisdiction}&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Meaning:&amp;nbsp;&lt;SPAN&gt;Look in the &lt;/SPAN&gt;&lt;STRONG&gt;region.csv&lt;/STRONG&gt;&lt;SPAN&gt; file, find the row where &lt;/SPAN&gt;&lt;STRONG&gt;name = selected jurisdiction&lt;/STRONG&gt;&lt;SPAN&gt;, and return the &lt;/SPAN&gt;&lt;STRONG&gt;region&lt;/STRONG&gt;&lt;SPAN&gt; value.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Mar 2026 10:04:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689304#M65597</guid>
      <dc:creator>hmorgan</dc:creator>
      <dc:date>2026-03-09T10:04:24Z</dc:date>
    </item>
    <item>
      <title>Re: Autopopulate a field based on previous question</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689551#M65609</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/881836"&gt;@hmorgan&lt;/a&gt;&amp;nbsp;thanks for the reply! That worked!&lt;/P&gt;</description>
      <pubDate>Mon, 09 Mar 2026 23:29:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/autopopulate-a-field-based-on-previous-question/m-p/1689551#M65609</guid>
      <dc:creator>GeoWorld13</dc:creator>
      <dc:date>2026-03-09T23:29:59Z</dc:date>
    </item>
  </channel>
</rss>

