<?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 How to delete the empty feature class from gdb or mdb arcgis 10.4.1 in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106391#M8215</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Friends,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please find the attached gdb. How to delete the empty feature class from gdb.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 03 Jul 2017 12:04:21 GMT</pubDate>
    <dc:creator>santhoshp</dc:creator>
    <dc:date>2017-07-03T12:04:21Z</dc:date>
    <item>
      <title>How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106391#M8215</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Friends,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please find the attached gdb. How to delete the empty feature class from gdb.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jul 2017 12:04:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106391#M8215</guid>
      <dc:creator>santhoshp</dc:creator>
      <dc:date>2017-07-03T12:04:21Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106392#M8216</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;the &lt;A href="http://desktop.arcgis.com/en/arcmap/latest/tools/data-management-toolbox/delete.htm"&gt;Delete tool &lt;/A&gt;pretty well covers how to delete a featureclass... with a series of "can't do".&amp;nbsp; You will have to elaborate why you can't delete one (ps, see the code example&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jul 2017 12:44:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106392#M8216</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-07-03T12:44:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106393#M8217</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Santhosh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can manually right click on the tables in ArcCatalog and select "delete". &amp;nbsp;You could also write a python script to loop through each feature class, and where total count = 0, run&amp;nbsp;the tool that Dan suggested.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcpy
&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcpy &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; env
env&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;workspace &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;'D:/YourPathHere/Power.mdb'&lt;/SPAN&gt;

data_sets &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;ListDatasets&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; item &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; data_sets&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; fcList &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;ListFeatureClasses&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; &lt;SPAN class="string token"&gt;''&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; item&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; item &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; fcList&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; fcLength &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;GetCount_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;item&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; int&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;fcLength&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;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;==&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;0&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;Delete_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;item&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;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 06:28:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106393#M8217</guid>
      <dc:creator>AlexanderBrown5</dc:creator>
      <dc:date>2021-12-11T06:28:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106394#M8218</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV style="display: none;"&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;DIV style="display: none;"&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;Thanks for reply but I am getting error.&lt;/DIV&gt;&lt;DIV&gt;Below the Snapshot .&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;My Path :E:\YourPathHere\Power.mdb.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jul 2017 08:02:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106394#M8218</guid>
      <dc:creator>santhoshp</dc:creator>
      <dc:date>2017-07-04T08:02:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106395#M8219</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;YourPathHere was changed in your real script, wasn't it? and does it exist&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jul 2017 08:40:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106395#M8219</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-07-04T08:40:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106396#M8220</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do add to Dan's question, please post the specific code generating the error and the whole error message.&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jul 2017 16:24:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106396#M8220</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2017-07-05T16:24:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106397#M8221</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Santhosh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are running my snippet from above (looks like you are from your error message attached)...your syntax is incorrect based on improper spacing. &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I copied my snippet directly into idle and did not have an issue, but it looks like something got out of alignment in your error. &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please make sure your indentation is correct:&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="http://geospatialtraining.com/10-common-python-errors-of-beginning-arcgis-programmers/" title="http://geospatialtraining.com/10-common-python-errors-of-beginning-arcgis-programmers/"&gt;10 Common Python Errors of Beginning ArcGIS Programmers |&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://docs.python.org/2.0/ref/indentation.html" title="https://docs.python.org/2.0/ref/indentation.html"&gt;2.1.7 Indentation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Make sure your Power.mdb is actually located here "&lt;SPAN style="background-color: #ffffff;"&gt;E:\YourPathHere\Power.mdb." &amp;nbsp;You could have updated this path to something else, I was literally saying "Your path on your computer to your access database here." &amp;nbsp; You created a new path instead of updating the line within the code.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;~Alex&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Jul 2017 19:16:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106397#M8221</guid>
      <dc:creator>AlexanderBrown5</dc:creator>
      <dc:date>2017-07-05T19:16:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to delete the empty feature class from gdb or mdb arcgis 10.4.1</title>
      <link>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106398#M8222</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Alex,&lt;/P&gt;&lt;P&gt;Thank you so much for your help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jul 2017 12:00:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-delete-the-empty-feature-class-from-gdb-or/m-p/106398#M8222</guid>
      <dc:creator>santhoshp</dc:creator>
      <dc:date>2017-07-06T12:00:12Z</dc:date>
    </item>
  </channel>
</rss>

