<?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: How to display the last value from a repeat field in the parent record in Survey123? in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/how-to-display-the-last-value-from-a-repeat-field/m-p/1636950#M63556</link>
    <description>&lt;P&gt;I would try this with indexed-repeat first, that way you are not relying on online content to populate the answer.&lt;/P&gt;&lt;P&gt;to get that to work you will need to know how many repeats you have so you can have a dynamic indexed repeat calculation.&lt;/P&gt;&lt;P&gt;create a helper field outside the repeat and use the count function to get a count of your repeats.&lt;/P&gt;&lt;P&gt;name: heridos_count&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; count(${&lt;SPAN&gt;heridos})&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformrepeats.htm#ESRI_SECTION1_045B883052D844E89F8EEFF8C2EA638A" target="_blank" rel="noopener"&gt;https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformrepeats.htm#ESRI_SECTION1_045B883052D844E89F8EEFF8C2EA638A&lt;/A&gt;&lt;/P&gt;&lt;P&gt;then use that field in your indexed-repeat calculation&lt;/P&gt;&lt;LI-CODE lang="markdown"&gt;indexed-repeat(${heridos}, ${reporte_evento}, ${heridos_count})&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;edit: add screenshot:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Neal_t_k_0-1753719299850.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/137361i11FE61AD1F4A39B6/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Neal_t_k_0-1753719299850.png" alt="Neal_t_k_0-1753719299850.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 28 Jul 2025 16:15:06 GMT</pubDate>
    <dc:creator>Neal_t_k</dc:creator>
    <dc:date>2025-07-28T16:15:06Z</dc:date>
    <item>
      <title>How to display the last value from a repeat field in the parent record in Survey123?</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/how-to-display-the-last-value-from-a-repeat-field/m-p/1636933#M63554</link>
      <description>&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;I'm building a Survey123 form in Connect, and I need help assigning the most recent value from a field inside a repeat in a field outside the repeat (i.e., in the parent layer).&lt;/P&gt;&lt;P&gt;Here's my structure:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;A repeat called reporte_evento, which includes a field named heridos (injured).&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Outside the repeat, I have a field called ult_envio_heridos where I want to automatically show the most recent value entered for heridos within the repeat.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;What is the recommended way to achieve this?&lt;/P&gt;&lt;P&gt;I've seen references to pulldata("@last"), indexed-repeat(), and even pulldata("@layer"), but i couldn't get neither of them to work ,the&amp;nbsp;ult_envio_heridos in the parent layer appears empty every time&lt;/P&gt;&lt;P&gt;Is there an official approach for this pattern?&lt;/P&gt;&lt;P&gt;Thanks in advance for your help!&lt;/P&gt;</description>
      <pubDate>Mon, 28 Jul 2025 15:38:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/how-to-display-the-last-value-from-a-repeat-field/m-p/1636933#M63554</guid>
      <dc:creator>JuanTomásMartinez17</dc:creator>
      <dc:date>2025-07-28T15:38:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to display the last value from a repeat field in the parent record in Survey123?</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/how-to-display-the-last-value-from-a-repeat-field/m-p/1636950#M63556</link>
      <description>&lt;P&gt;I would try this with indexed-repeat first, that way you are not relying on online content to populate the answer.&lt;/P&gt;&lt;P&gt;to get that to work you will need to know how many repeats you have so you can have a dynamic indexed repeat calculation.&lt;/P&gt;&lt;P&gt;create a helper field outside the repeat and use the count function to get a count of your repeats.&lt;/P&gt;&lt;P&gt;name: heridos_count&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; count(${&lt;SPAN&gt;heridos})&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformrepeats.htm#ESRI_SECTION1_045B883052D844E89F8EEFF8C2EA638A" target="_blank" rel="noopener"&gt;https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformrepeats.htm#ESRI_SECTION1_045B883052D844E89F8EEFF8C2EA638A&lt;/A&gt;&lt;/P&gt;&lt;P&gt;then use that field in your indexed-repeat calculation&lt;/P&gt;&lt;LI-CODE lang="markdown"&gt;indexed-repeat(${heridos}, ${reporte_evento}, ${heridos_count})&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;edit: add screenshot:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Neal_t_k_0-1753719299850.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/137361i11FE61AD1F4A39B6/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Neal_t_k_0-1753719299850.png" alt="Neal_t_k_0-1753719299850.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Jul 2025 16:15:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/how-to-display-the-last-value-from-a-repeat-field/m-p/1636950#M63556</guid>
      <dc:creator>Neal_t_k</dc:creator>
      <dc:date>2025-07-28T16:15:06Z</dc:date>
    </item>
  </channel>
</rss>

