<?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: &amp;quot;executeQuery&amp;quot; of DataSourceProxy Class has wrong behavior on Browser in ArcGIS Dashboards Questions</title>
    <link>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196147#M1092</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Noppadon, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for sending in the sample. I am able to reproduce this problem using my own data, and it seems to be a bug in our API. I noticed that when this.dataSourceProxy.executeQuery(this.query) is called, the buffer's geometry is already dropped from the params of the request, which possibly explains why all features are returned. I have logged a bug into our system and will work with our developers on this. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As you pointed out in &lt;A _jive_internal="true" href="https://community.esri.com/thread/168560"&gt;another post &lt;/A&gt;in the forum, you can use the &lt;A href="https://developers.arcgis.com/javascript/jsapi/querytask-amd.html#execute"&gt;QueryTask.execute()&lt;/A&gt; method as a workaround. I have tried that by replacing the "this.dataSourceProxy.executeQuery(this.query).then(lang.hitch(this, function(results) {}));" block by the following code block, and the table would be populated correctly in the both desktop and browser platforms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var url = "&amp;lt;url to your data source&amp;gt;";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var queryTask = new QueryTask(url, null); &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; queryTask.execute(this.query).then(lang.hitch(this, function(results){&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.createTable(results);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 15 Dec 2015 00:40:57 GMT</pubDate>
    <dc:creator>TifPun</dc:creator>
    <dc:date>2015-12-15T00:40:57Z</dc:date>
    <item>
      <title>"executeQuery" of DataSourceProxy Class has wrong behavior on Browser</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196145#M1090</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, I make custom widget with Javascript that has simple workflow like below.&lt;/P&gt;&lt;P&gt;1. User select datasouce and field that they want to display&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="138919" alt="set.png" class="image-3 jive-image" src="https://community.esri.com/legacyfs/online/138919_set.png" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;2. User locate location to draw buffer and query selected DataSource with that buffer's geometry to find feature and list them to table.&lt;/P&gt;&lt;P&gt;Well, &lt;STRONG&gt;It's work fine in desktop Application.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="138917" alt="Desktop.png" class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/138917_Desktop.png" style="width: 620px; height: 371px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But when I test it on &lt;STRONG&gt;browser.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I got different results here with the same widget.&lt;/P&gt;&lt;P&gt;It list all feature of selected DataSource to table.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="138918" alt="Browser.png" class="image-2 jive-image" src="https://community.esri.com/legacyfs/online/138918_Browser.png" style="width: 620px; height: 563px;" /&gt;&lt;/P&gt;&lt;P&gt;So, I inspect query that fire out.&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="138923" alt="Params.png" class="image-4 jive-image" height="122" src="https://community.esri.com/legacyfs/online/138923_Params.png" style="height: 122px; width: 879.535px;" width="880" /&gt;&lt;/P&gt;&lt;P&gt;and found that &lt;SPAN style="color: #e23d39;"&gt;&lt;STRONG&gt;geometry's param was ignore in browser&lt;/STRONG&gt;&lt;/SPAN&gt; so it return all of feature back.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #e23d39;"&gt;**&lt;/SPAN&gt; I use "executeQuery" method of&amp;nbsp; &lt;A href="https://developers.arcgis.com/javascript/jsapi/datasourceproxy-amd.html#executequery"&gt;DataSourceProxy &lt;/A&gt;Class to query instead of QueryTask because I want to query with selected Datasource without fix service URL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I already attach this widget. You can download and test it with some featureLayer on Dashboard.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Nov 2015 09:01:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196145#M1090</guid>
      <dc:creator>NoppadonHimananto</dc:creator>
      <dc:date>2015-11-05T09:01:19Z</dc:date>
    </item>
    <item>
      <title>Re: "executeQuery" of DataSourceProxy Class has wrong behavior on Browser</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196146#M1091</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN class="st"&gt;&lt;EM&gt;can anyone test and confirm this?&lt;BR /&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="st"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="st"&gt;&lt;EM&gt;Thank you.&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Nov 2015 10:47:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196146#M1091</guid>
      <dc:creator>NoppadonHimananto</dc:creator>
      <dc:date>2015-11-09T10:47:24Z</dc:date>
    </item>
    <item>
      <title>Re: "executeQuery" of DataSourceProxy Class has wrong behavior on Browser</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196147#M1092</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Noppadon, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for sending in the sample. I am able to reproduce this problem using my own data, and it seems to be a bug in our API. I noticed that when this.dataSourceProxy.executeQuery(this.query) is called, the buffer's geometry is already dropped from the params of the request, which possibly explains why all features are returned. I have logged a bug into our system and will work with our developers on this. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As you pointed out in &lt;A _jive_internal="true" href="https://community.esri.com/thread/168560"&gt;another post &lt;/A&gt;in the forum, you can use the &lt;A href="https://developers.arcgis.com/javascript/jsapi/querytask-amd.html#execute"&gt;QueryTask.execute()&lt;/A&gt; method as a workaround. I have tried that by replacing the "this.dataSourceProxy.executeQuery(this.query).then(lang.hitch(this, function(results) {}));" block by the following code block, and the table would be populated correctly in the both desktop and browser platforms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var url = "&amp;lt;url to your data source&amp;gt;";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; var queryTask = new QueryTask(url, null); &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; queryTask.execute(this.query).then(lang.hitch(this, function(results){&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.createTable(results);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Dec 2015 00:40:57 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196147#M1092</guid>
      <dc:creator>TifPun</dc:creator>
      <dc:date>2015-12-15T00:40:57Z</dc:date>
    </item>
    <item>
      <title>Re: "executeQuery" of DataSourceProxy Class has wrong behavior on Browser</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196148#M1093</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tif,&lt;/P&gt;&lt;P&gt;Thanks for letting me know.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 04 Jan 2016 08:29:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196148#M1093</guid>
      <dc:creator>NoppadonHimananto</dc:creator>
      <dc:date>2016-01-04T08:29:10Z</dc:date>
    </item>
    <item>
      <title>Re: "executeQuery" of DataSourceProxy Class has wrong behavior on Browser</title>
      <link>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196149#M1094</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi again Noppadon, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This bug has been fixed and has passed our testing. The fix will be available in the next release of browser Dashboard. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please let us know if you have more questions, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tif&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 23:38:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-dashboards-questions/quot-executequery-quot-of-datasourceproxy-class/m-p/196149#M1094</guid>
      <dc:creator>TifPun</dc:creator>
      <dc:date>2016-05-25T23:38:51Z</dc:date>
    </item>
  </channel>
</rss>

