<?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 Feature Layers do not have all attributes in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451817#M10445</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;can anyone answer why a feature layer's graphics providers' attributes does not contain all of the layer's attributes unless it's queried? &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; var features:ArrayCollection = ArrayCollection(featureLayer.graphicProvider);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var featureSet:FeatureSet = new FeatureSet(features.source);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;featureSet.attributes would only have fields : ObjectID, Shape, and STFIPS. I want to be able to grab all of the attributes from the feature layer, but it seems the only way is to query the feature layer. is there another way because it seems that querying for each feature would take a performance hit.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 12 Oct 2010 14:12:52 GMT</pubDate>
    <dc:creator>BryanLin</dc:creator>
    <dc:date>2010-10-12T14:12:52Z</dc:date>
    <item>
      <title>Feature Layers do not have all attributes</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451817#M10445</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;can anyone answer why a feature layer's graphics providers' attributes does not contain all of the layer's attributes unless it's queried? &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt; var features:ArrayCollection = ArrayCollection(featureLayer.graphicProvider);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; var featureSet:FeatureSet = new FeatureSet(features.source);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;featureSet.attributes would only have fields : ObjectID, Shape, and STFIPS. I want to be able to grab all of the attributes from the feature layer, but it seems the only way is to query the feature layer. is there another way because it seems that querying for each feature would take a performance hit.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Oct 2010 14:12:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451817#M10445</guid>
      <dc:creator>BryanLin</dc:creator>
      <dc:date>2010-10-12T14:12:52Z</dc:date>
    </item>
    <item>
      <title>Re: Feature Layers do not have all attributes</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451818#M10446</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Have you set the outFields?&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/flex/apiref/com/esri/ags/layers/FeatureLayer.html#outFields"&gt;http://help.arcgis.com/en/webapi/flex/apiref/com/esri/ags/layers/FeatureLayer.html#outFields&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Oct 2010 16:27:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451818#M10446</guid>
      <dc:creator>DasaPaddock</dc:creator>
      <dc:date>2010-10-12T16:27:48Z</dc:date>
    </item>
    <item>
      <title>Re: Feature Layers do not have all attributes</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451819#M10447</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Have you set the outFields?&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/flex/apiref/com/esri/ags/layers/FeatureLayer.html#outFields"&gt;http://help.arcgis.com/en/webapi/flex/apiref/com/esri/ags/layers/FeatureLayer.html#outFields&lt;/A&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Yes i had that too. It still returns only objectid, shape,and stfips.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Oct 2010 17:11:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451819#M10447</guid>
      <dc:creator>BryanLin</dc:creator>
      <dc:date>2010-10-12T17:11:55Z</dc:date>
    </item>
    <item>
      <title>Re: Feature Layers do not have all attributes</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451820#M10448</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Can you post a test case? It sounds like your code is correct, but you may want to contact ESRI Tech Support to see if there's a bug here.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Oct 2010 17:20:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451820#M10448</guid>
      <dc:creator>DasaPaddock</dc:creator>
      <dc:date>2010-10-12T17:20:08Z</dc:date>
    </item>
    <item>
      <title>Re: Feature Layers do not have all attributes</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451821#M10449</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Can you post a test case? It sounds like your code is correct, but you may want to contact ESRI Tech Support to see if there's a bug here.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;var featureLayer:FeatureLayer = new FeatureLayer("&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://myserver/arcgis/rest/services/Example/MapServer" rel="nofollow" target="_blank"&gt;http://myserver/arcgis/rest/services/Example/MapServer&lt;/A&gt;&lt;SPAN&gt;")&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;var features:ArrayCollection = ArrayCollection(featureLayer.graphicProvider);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;var featureSet:FeatureSet = new FeatureSet(features.source)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;//find the attributes of the feature set&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;for each(var attribute:Object in featureSet.attributes)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; trace("attribute : " + attribute");&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;i believe you can also get the attribute names with:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;for (var attributeName:Object in featureSet.attributes)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; trace("attribute name: " + attributeName + " : " + featureSet.attributes[attributeName]);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Oct 2010 17:36:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451821#M10449</guid>
      <dc:creator>BryanLin</dc:creator>
      <dc:date>2010-10-12T17:36:20Z</dc:date>
    </item>
    <item>
      <title>Re: Feature Layers do not have all attributes</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451822#M10450</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The FeatureLayer url should be to a layer in the map service. e.g.,&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://myserver/arcgis/rest/services/Example/MapServer/0"&gt;http://myserver/arcgis/rest/services/Example/MapServer/0&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Also, FeatureSet.attributes is an Array of Objects, so you need an inner loop to pull out the values of the attributes for each feature in the FeatureSet.&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/flex/apiref/com/esri/ags/FeatureSet.html#attributes"&gt;http://help.arcgis.com/en/webapi/flex/apiref/com/esri/ags/FeatureSet.html#attributes&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 12 Oct 2010 17:47:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/feature-layers-do-not-have-all-attributes/m-p/451822#M10450</guid>
      <dc:creator>DasaPaddock</dc:creator>
      <dc:date>2010-10-12T17:47:39Z</dc:date>
    </item>
  </channel>
</rss>

