<?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: Conditionally deleting records in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657985#M51211</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Bear with me as i dont have a good working understanding of Python.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for line 5 my path looks like this...&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt; color: black;"&gt;fc = ("x:\\Street_Level_Photography\\Street_Level_Photography.gdb\\Export_Output")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt; color: black;"&gt;and im getting the following: Error 000732: Input Features: Dataset x:/Street_Level_Photography/Street_Level_Photography.gdb/Export_Output does not exist or is not supported&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt; color: black;"&gt;Im guessing there is a syntax error. Im not sure if this makes a difference but the data is not stored locally, should i use the server name rather than the drive name? Server name would be gemini, my drive name is x&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Apr 2019 14:57:10 GMT</pubDate>
    <dc:creator>PrestonEllison</dc:creator>
    <dc:date>2019-04-04T14:57:10Z</dc:date>
    <item>
      <title>Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657981#M51207</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Im trying to come up with a way to conditionally delete some records in a table. For instance, i have variably shaped polygons that when spatially joined with a point feature class tend to result in excess points on the larger polygons. I would like to set up a definition query to select and eventually delete&amp;nbsp;every other or even every 2 out of 3 rows IF (and only if) there are, say more than 10 occurrences of that record. Im trying to implement this in arcmap via a python/sql query. Im sure there is way to do this in the output file (.csv) but I would like to maintain the integrity of the data in arcmap prior to exporting it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help on how to go about doing this?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Apr 2019 17:17:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657981#M51207</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-02T17:17:59Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657982#M51208</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I see what you are after, but it is hard to respond in abstract concepts.&amp;nbsp; If you can describe the structure of your data, and/or provide sample data, you will get better and more specific responses.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Apr 2019 17:44:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657982#M51208</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2019-04-02T17:44:06Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657983#M51209</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hopefully this help to provide some context. Im working with parcel data and gps tagged photos. After a spatial join the photo points are associated with a parcel or rather an "Account_Nu". Below is an example of a typical scenario where one parcel may grab 20 points and the adjacent parcel grabs 3 or 4 based upon the length of existing road frontage. 3 or 4 pictures per parcel is desirable but anything over 10 is a bit excessive. I can parse these points down by running the delete identical tool but im limited to about a 10 ft buffer.&amp;nbsp;&lt;SPAN&gt;The reason being is some parcels only have 30 or 40 ft of road frontage and&amp;nbsp;&lt;/SPAN&gt;im trying to at least get a couple points per parcel, any larger buffer and i could exclude entire parcels all together. The goal is to indiscriminately delete every other (or every 2 out of 3) point to still provide coverage&amp;nbsp;but keep it trimmed as best as possible.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="image-1 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/440956_layout.JPG" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is a snapshot of the table, the "Account_Nu"&amp;nbsp; being the primary field used to clean up the data. As you can see, multiple Account_Nu's are associated with many JPGs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="image-2 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/440988_table.JPG" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Apr 2019 18:54:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657983#M51209</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-02T18:54:25Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657984#M51210</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try the following in the interactive Python window (modify Lines #05 &amp;amp; #08).&amp;nbsp; The code will select the records to keep, which you can invert to select the records to delete.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; collections &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; Counter
&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; itertools &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; groupby
&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; operator &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; itemgetter

fc &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="comment token"&gt;# path to feature class&lt;/SPAN&gt;
group_size &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;4&lt;/SPAN&gt;
case_fields &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"Account_Nu"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;
sort_field &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"Image_Date"&lt;/SPAN&gt;  &lt;SPAN class="comment token"&gt;# Insert name of field with image dates&lt;/SPAN&gt;
sql_orderby &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"ORDER BY {}, {}"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;format&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;", "&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;join&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;case_fields&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; sort_field&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;

fl &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;MakeFeatureLayer_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;fc&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"fl"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;getOutput&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;0&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
oidName &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;Describe&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;fl&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;OIDFieldName
oids &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;

&lt;SPAN class="keyword token"&gt;with&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;da&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;SearchCursor&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;fl&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"*"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; sql_clause&lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;None&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; sql_orderby&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;as&lt;/SPAN&gt; cur&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
    oidField &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; cur&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;fields&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;index&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;oidName&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
    case_func &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; itemgetter&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;
        &lt;SPAN class="operator token"&gt;*&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;cur&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;fields&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;index&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;fld&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; fld &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; case_fields&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
    &lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
    count &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; Counter&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;case_func&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;row&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; row &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; cur&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
    cur&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;reset&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
    
    &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; key&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; group &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; groupby&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;cur&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; case_func&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
        group_step &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;
            slice&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;None&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
            &lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; count&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;key&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;&amp;lt;&lt;/SPAN&gt; group_size &lt;SPAN class="keyword token"&gt;else&lt;/SPAN&gt;
            slice&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;count&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;key&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;%&lt;/SPAN&gt;group_size&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt;None&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt;count&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;key&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;//&lt;/SPAN&gt;group_size&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
        &lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
        oids &lt;SPAN class="operator token"&gt;+=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;row&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;oidField&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; row &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; list&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;group&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;[&lt;/SPAN&gt;group_step&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;]&lt;/SPAN&gt;

fl&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;setSelectionSet&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"NEW_SELECTION"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; oids&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 03:51:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657984#M51210</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2021-12-12T03:51:09Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657985#M51211</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Bear with me as i dont have a good working understanding of Python.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for line 5 my path looks like this...&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt; color: black;"&gt;fc = ("x:\\Street_Level_Photography\\Street_Level_Photography.gdb\\Export_Output")&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt; color: black;"&gt;and im getting the following: Error 000732: Input Features: Dataset x:/Street_Level_Photography/Street_Level_Photography.gdb/Export_Output does not exist or is not supported&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 12.0pt; color: black;"&gt;Im guessing there is a syntax error. Im not sure if this makes a difference but the data is not stored locally, should i use the server name rather than the drive name? Server name would be gemini, my drive name is x&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 14:57:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657985#M51211</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-04T14:57:10Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657986#M51212</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is it a lower case x or and upper case X?&amp;nbsp; that'll make a difference.&amp;nbsp; Just as a matter of style, when setting paths, I prefer to use the 'r' functionality in python which allows you enter &lt;STRONG&gt;r&lt;/STRONG&gt;aw text.&amp;nbsp; I'm lazy and would rather let the computer escape special characters like the \ .&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;fc &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; r&lt;SPAN class="string token"&gt;'C:\path\to\gdb\featureclass'&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 16:01:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657986#M51212</guid>
      <dc:creator>JoeBorgione</dc:creator>
      <dc:date>2019-04-04T16:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657987#M51213</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As &lt;A href="https://community.esri.com/migrated-users/4422"&gt;Joe Borgione&lt;/A&gt;‌ points out, you are currently setting &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;fc&lt;/SPAN&gt; to a tuple containing a string, not a string.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 16:14:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657987#M51213</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2019-04-04T16:14:02Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657988#M51214</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I was able to get it to the code run successfully and create the feature layer output, however the new feature layer (fl) is just a copy of the original feature class. 8527 records input, 8527 records output.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 17:12:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657988#M51214</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-04T17:12:40Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657989#M51215</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Feature layer and table views are not copies of data, they are views of data.&amp;nbsp; If you have a feature class open in ArcMap, you are looking at a feature layer, often times it has the same name as the feature class it is referencing.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The code as written should be creating a new feature layer, which is appears to be doing, but it should also be selecting some records from that feature layer.&amp;nbsp; If you open up the attribute table of the &lt;SPAN style="font-family: courier new, courier, monospace;"&gt;fl&lt;/SPAN&gt; feature layer, are any records selected?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 17:37:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657989#M51215</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2019-04-04T17:37:13Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657990#M51216</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There were no records selected. Here is the results window if it helps&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="image-1 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/441223_Capture.JPG" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 17:49:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657990#M51216</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-04T17:49:00Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657991#M51217</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you type the following after the code runs, what do you get:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;oids&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tested the code on some sample data on my machine before posting it, so I think the logic and code are sound.&amp;nbsp; Can you post either a subset and/or sanitized set of data here for me to test on?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 18:14:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657991#M51217</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2019-04-04T18:14:53Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657992#M51218</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Absolutely, whats the best route to get you a sample data set?&lt;/P&gt;&lt;P&gt;When i run the print, I get the following....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="image-1 jive-image j-img-original" src="https://community.esri.com/legacyfs/online/441227_Capture.JPG" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 18:46:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657992#M51218</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-04T18:46:50Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657993#M51219</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just looking at your screenshot, you left off the last line, the one that actually selects the records:&lt;/P&gt;&lt;PRE class="language-python line-numbers"&gt;&lt;CODE&gt;fl&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;setSelectionSet&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"NEW_SELECTION"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; oids&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 19:03:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657993#M51219</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2019-04-04T19:03:00Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657994#M51220</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yikes, how did i miss that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It works! This is perfect. Im assuming i could change the frequency of the selection by adjusting line 6 "group size"&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 19:11:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657994#M51220</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-04T19:11:25Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657995#M51221</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, the group_size variable sets how many photo points you want per Account_Nu, roughly.&amp;nbsp; If you only have 3 points and the group size is 6, it will just select all 3.&amp;nbsp; The trick that took a bit of thought was how to get staggered points along the photo traversing path.&amp;nbsp; Grabbing the first or last x number of photos is easy, but I figured you don't want just 4 photos at the start of the property if there are 50 photos along the perimeter of the property.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 20:12:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657995#M51221</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2019-04-04T20:12:55Z</dc:date>
    </item>
    <item>
      <title>Re: Conditionally deleting records</title>
      <link>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657996#M51222</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Exactly. The idea was to get a representative view of the entire property vs just a cluster of points from roughly the same location.The way this is set up is extremely helpful and i cant thank you enough.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Apr 2019 20:25:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/conditionally-deleting-records/m-p/657996#M51222</guid>
      <dc:creator>PrestonEllison</dc:creator>
      <dc:date>2019-04-04T20:25:18Z</dc:date>
    </item>
  </channel>
</rss>

