<?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 Help! search() function not working as documented in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/help-search-function-not-working-as-documented/m-p/1265601#M47861</link>
    <description>&lt;P&gt;Hey all,&lt;/P&gt;&lt;P&gt;Hoping someone can help troubleshoot why the search() function isn't working as documented for me.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Overview&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I'm trying to put together a simple search() query for a question that returns attendees but only for a specific event. The attendance list is a child table and I'm aiming to have the search function return attendees based on the parent event point selected.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Referring to the &lt;A href="https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformsappearance.htm#ESRI_SECTION1_46A700D2AABF47F1AE4D5004762DB372" target="_self"&gt;documentation for search()&lt;/A&gt;, the following example was given:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;search('csvName', 'matches', 'breed', ${DogQuestion})&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;I set up a very similar query (though instead of a csv, it was pointing to the related table in the feature layer):&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;search('table_example?url=&amp;lt;url&amp;gt;/FeatureServer/3', 'matches', 'parentglobalid', ${parentglobalid})&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;However, this returns the&amp;nbsp;&lt;STRONG&gt;entire &lt;/STRONG&gt;attendance list instead of just those that match the parentglobalid .&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Vinzafy_3-1678297854254.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/64720i9177928C41E14107/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Vinzafy_3-1678297854254.png" alt="Vinzafy_3-1678297854254.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;The list should only show First1, Last1; First2, Last2; etc.&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;When manually entering the parentglobalid of a test event however, it returns the expected results.&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;search('table_example?url=&amp;lt;url&amp;gt;/FeatureServer/3', 'matches', 'parentglobalid', '57ad118f-bcb0-41a1-8268-c2d2b7f79512')&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Vinzafy_2-1678297821788.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/64719i22979DB76D38331F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Vinzafy_2-1678297821788.png" alt="Vinzafy_2-1678297821788.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;This returns the proper list of attendees for that example event.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;It seems that the search() function wants the searchText parameter to be enclosed in quotes (' ') , however the documentation has it calling a specific field.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Troubleshooting Attempts&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I tried creating a secondary field to contain the parentglobalid as a string (though the original field was a text question type already), having that field calculate to put the parentglobalid in quotes (concat("'", ${parentglobalid}, "'")), and even tried calling a completely different field not related to the searchColumn, but those all returned the entire list.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help would be much appreciated! Hopefully I'm just missing something obvious.&lt;/P&gt;</description>
    <pubDate>Wed, 08 Mar 2023 17:57:35 GMT</pubDate>
    <dc:creator>Vince_ERAC</dc:creator>
    <dc:date>2023-03-08T17:57:35Z</dc:date>
    <item>
      <title>Help! search() function not working as documented</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/help-search-function-not-working-as-documented/m-p/1265601#M47861</link>
      <description>&lt;P&gt;Hey all,&lt;/P&gt;&lt;P&gt;Hoping someone can help troubleshoot why the search() function isn't working as documented for me.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Overview&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I'm trying to put together a simple search() query for a question that returns attendees but only for a specific event. The attendance list is a child table and I'm aiming to have the search function return attendees based on the parent event point selected.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Referring to the &lt;A href="https://doc.arcgis.com/en/survey123/desktop/create-surveys/xlsformsappearance.htm#ESRI_SECTION1_46A700D2AABF47F1AE4D5004762DB372" target="_self"&gt;documentation for search()&lt;/A&gt;, the following example was given:&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;search('csvName', 'matches', 'breed', ${DogQuestion})&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;I set up a very similar query (though instead of a csv, it was pointing to the related table in the feature layer):&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;search('table_example?url=&amp;lt;url&amp;gt;/FeatureServer/3', 'matches', 'parentglobalid', ${parentglobalid})&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;However, this returns the&amp;nbsp;&lt;STRONG&gt;entire &lt;/STRONG&gt;attendance list instead of just those that match the parentglobalid .&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Vinzafy_3-1678297854254.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/64720i9177928C41E14107/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Vinzafy_3-1678297854254.png" alt="Vinzafy_3-1678297854254.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;The list should only show First1, Last1; First2, Last2; etc.&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;When manually entering the parentglobalid of a test event however, it returns the expected results.&lt;/SPAN&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;SPAN&gt;search('table_example?url=&amp;lt;url&amp;gt;/FeatureServer/3', 'matches', 'parentglobalid', '57ad118f-bcb0-41a1-8268-c2d2b7f79512')&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Vinzafy_2-1678297821788.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/64719i22979DB76D38331F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Vinzafy_2-1678297821788.png" alt="Vinzafy_2-1678297821788.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;This returns the proper list of attendees for that example event.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;It seems that the search() function wants the searchText parameter to be enclosed in quotes (' ') , however the documentation has it calling a specific field.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Troubleshooting Attempts&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I tried creating a secondary field to contain the parentglobalid as a string (though the original field was a text question type already), having that field calculate to put the parentglobalid in quotes (concat("'", ${parentglobalid}, "'")), and even tried calling a completely different field not related to the searchColumn, but those all returned the entire list.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help would be much appreciated! Hopefully I'm just missing something obvious.&lt;/P&gt;</description>
      <pubDate>Wed, 08 Mar 2023 17:57:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/help-search-function-not-working-as-documented/m-p/1265601#M47861</guid>
      <dc:creator>Vince_ERAC</dc:creator>
      <dc:date>2023-03-08T17:57:35Z</dc:date>
    </item>
  </channel>
</rss>

