<?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: Feature Layer vs Query Task in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/feature-layer-vs-query-task/m-p/140173#M13011</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Peter,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Much of that is dependent on your full use case. Does the map already have that FeatureLayer added? If so then using FeatureLayer.queryFeatures may be a better route because:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;SPAN style="color: #4d4d4d; font-family: 'Lucida Grande', 'Segoe UI', Arial, sans-serif; font-size: 14px; font-style: normal; font-weight: normal; text-align: start; text-indent: 0px;"&gt;Query features from the feature layer. Layer definition and time definition are honored. Whenever possible the feature layer will perform the query on the client.&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Will you need to show the full feature layer in the map as well as distinguish the queried results differently form the rest of the features, or do you only want to see the queried features in the map?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You may want to look into adding the FeatureLayer to the map in selection mode "MODE_SELECTION" and the selectFeatures method, if you only want to see the results of the selection in the map.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 21 Apr 2015 13:08:50 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2015-04-21T13:08:50Z</dc:date>
    <item>
      <title>Feature Layer vs Query Task</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/feature-layer-vs-query-task/m-p/140172#M13010</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm using ArcGIS Javascript API, and I need to query the GIS and show the results on the map.&amp;nbsp; Currently I have used a Query Task by specifying the layer,&amp;nbsp; the "where" statement,&amp;nbsp; graphic symbol, InfoTemplate etc. and it works well.&amp;nbsp; I'm wondering however whether I should be using a Feature Layer with a Definition Expression, rather than the Query Task.&amp;nbsp; Using a Feature Layer would enable the drawing information from the server to be used.&amp;nbsp; Also the symbol would show in the legend.&amp;nbsp; When is it better to use a Query Task rather then a Feature Layer?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Feb 2015 20:04:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/feature-layer-vs-query-task/m-p/140172#M13010</guid>
      <dc:creator>PeterHunt3</dc:creator>
      <dc:date>2015-02-11T20:04:05Z</dc:date>
    </item>
    <item>
      <title>Re: Feature Layer vs Query Task</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/feature-layer-vs-query-task/m-p/140173#M13011</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Peter,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Much of that is dependent on your full use case. Does the map already have that FeatureLayer added? If so then using FeatureLayer.queryFeatures may be a better route because:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;SPAN style="color: #4d4d4d; font-family: 'Lucida Grande', 'Segoe UI', Arial, sans-serif; font-size: 14px; font-style: normal; font-weight: normal; text-align: start; text-indent: 0px;"&gt;Query features from the feature layer. Layer definition and time definition are honored. Whenever possible the feature layer will perform the query on the client.&lt;/SPAN&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Will you need to show the full feature layer in the map as well as distinguish the queried results differently form the rest of the features, or do you only want to see the queried features in the map?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You may want to look into adding the FeatureLayer to the map in selection mode "MODE_SELECTION" and the selectFeatures method, if you only want to see the results of the selection in the map.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Apr 2015 13:08:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/feature-layer-vs-query-task/m-p/140173#M13011</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2015-04-21T13:08:50Z</dc:date>
    </item>
  </channel>
</rss>

