<?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: Getting string data from a shape file attribute table in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89808#M6958</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;A class="jive-link-external-small" href="http://resources.arcgis.com/en/help/main/10.2/index.html#//018w00000011000000" rel="nofollow" target="_blank"&gt;Some help here...&lt;/A&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;import arcpy&amp;nbsp; fc = 'yourfeatureclass' strfld = 'yourstringfield'&amp;nbsp; with arcpy.da.SearchCursor(fc, strFld) as cur: &amp;nbsp;&amp;nbsp;&amp;nbsp; for row in cur: &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; valueyouwant = row[0] &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # do something with valueyouwant &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 02 Jun 2014 11:12:14 GMT</pubDate>
    <dc:creator>Zeke</dc:creator>
    <dc:date>2014-06-02T11:12:14Z</dc:date>
    <item>
      <title>Getting string data from a shape file attribute table</title>
      <link>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89807#M6957</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am looking to extract string field from a shapefile attribute table to then allow me to do a number of IF logic calculations but I am not sure how to get that specific field from the shapefile to the allow me to script the calculations.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help or pointers would be very much appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Fiona&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Jun 2014 10:48:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89807#M6957</guid>
      <dc:creator>fionasimpson</dc:creator>
      <dc:date>2014-06-02T10:48:56Z</dc:date>
    </item>
    <item>
      <title>Re: Getting string data from a shape file attribute table</title>
      <link>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89808#M6958</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;A class="jive-link-external-small" href="http://resources.arcgis.com/en/help/main/10.2/index.html#//018w00000011000000" rel="nofollow" target="_blank"&gt;Some help here...&lt;/A&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;import arcpy&amp;nbsp; fc = 'yourfeatureclass' strfld = 'yourstringfield'&amp;nbsp; with arcpy.da.SearchCursor(fc, strFld) as cur: &amp;nbsp;&amp;nbsp;&amp;nbsp; for row in cur: &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; valueyouwant = row[0] &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; # do something with valueyouwant &amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Jun 2014 11:12:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89808#M6958</guid>
      <dc:creator>Zeke</dc:creator>
      <dc:date>2014-06-02T11:12:14Z</dc:date>
    </item>
    <item>
      <title>Re: Getting string data from a shape file attribute table</title>
      <link>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89809#M6959</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;That's great i have it working now.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Fiona&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 02 Jun 2014 13:16:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/getting-string-data-from-a-shape-file-attribute/m-p/89809#M6959</guid>
      <dc:creator>fionasimpson</dc:creator>
      <dc:date>2014-06-02T13:16:55Z</dc:date>
    </item>
  </channel>
</rss>

