<?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: arcpy.Exists working in interactive window but not stand-alone script in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386043#M30456</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Dan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I also had concerns about the funky path, but as I mentioned, the arcpy.Exists() work for the geodatabase itself, which implies to me that the path is not the problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, I am writing code for others to use, so I don't have control over their file-naming convention or the type of geodatabase they are using. &amp;nbsp; &amp;nbsp;If that is the problem, I will need to find a different way to code this check, but it would be nice to know why the Exists function is so inconsistent.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 01 Sep 2017 18:38:27 GMT</pubDate>
    <dc:creator>AllisonBailey</dc:creator>
    <dc:date>2017-09-01T18:38:27Z</dc:date>
    <item>
      <title>arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386041#M30454</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am having trouble with the arcpy.Exists() function in a script&amp;nbsp;to check the existence of a table in a personal geodatabase.&amp;nbsp; &amp;nbsp;When I test in the ArcToolbox Python window, I get the correct result, True, for a table that exists.&amp;nbsp; &amp;nbsp;When I use the same commands in a stand-alone script, regardless of how&amp;nbsp;I construct the path string, it always returns False for the table. &amp;nbsp; &amp;nbsp;I also tested just the geodatabase, and it returns True, so it is not having trouble finding the geodatabase itself. &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is the code from the script. &amp;nbsp; When I run from the interactive window, I just remove the print statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P class=""&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;import &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P class=""&gt;&lt;SPAN class=""&gt;&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;print &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy.Exists(&lt;/SPAN&gt;&lt;STRONG&gt;"Y:/projects/dnr_svmp2016/db/SVMP_2000_2015_DB.v52_20170803/SVMP_DB_v5.2_20170803_AB.mdb/site_samples"&lt;/STRONG&gt;&lt;SPAN class=""&gt;)&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;print &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy.Exists(&lt;/SPAN&gt;&lt;STRONG&gt;"Y:\projects\dnr_svmp2016\db\SVMP_2000_2015_DB.v52_20170803\SVMP_DB_v5.2_20170803_AB.mdb\site_samples"&lt;/STRONG&gt;&lt;SPAN class=""&gt;)&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;print &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy.Exists(&lt;/SPAN&gt;&lt;STRONG&gt;"Y:&lt;/STRONG&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;\\&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;projects&lt;/STRONG&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;\\&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;dnr_svmp2016&lt;/STRONG&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;\\&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;db&lt;/STRONG&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;\\&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;SVMP_2000_2015_DB.v52_20170803&lt;/STRONG&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;\\&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;SVMP_DB_v5.2_20170803_AB.mdb&lt;/STRONG&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;\\&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;site_samples"&lt;/STRONG&gt;&lt;SPAN class=""&gt;)&lt;BR /&gt; &lt;/SPAN&gt;&lt;SPAN class=""&gt;&lt;STRONG&gt;print &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN class=""&gt;arcpy.Exists(&lt;/SPAN&gt;&lt;STRONG&gt;"Y:/projects/dnr_svmp2016/db/SVMP_2000_2015_DB.v52_20170803/SVMP_DB_v5.2_20170803_AB.mdb"&lt;/STRONG&gt;&lt;SPAN class=""&gt;)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This script returns:&lt;/P&gt;&lt;P&gt;False&lt;/P&gt;&lt;P&gt;False&lt;/P&gt;&lt;P&gt;False&lt;/P&gt;&lt;P&gt;True&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is &amp;nbsp;screenshot of the interactive window:&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Screen shot of same commmands in ArcToolbox Python window" class="image-1 jive-image j-img-original" src="/legacyfs/online/369514_Screen Shot 2017-09-01 at 11.06.39 AM.png" style="width: 620px; height: 265px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm hoping that the solution is something very obvious that I am just missing right now! &amp;nbsp; Thanks for any help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 18:25:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386041#M30454</guid>
      <dc:creator>AllisonBailey</dc:creator>
      <dc:date>2017-09-01T18:25:34Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386042#M30455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just a hunch... try a &lt;STRONG&gt;file geodatabase&lt;/STRONG&gt; rather than a personal geodatabase... and one without periods in it and other extraneous characters&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 18:31:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386042#M30455</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-09-01T18:31:03Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386043#M30456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Dan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I also had concerns about the funky path, but as I mentioned, the arcpy.Exists() work for the geodatabase itself, which implies to me that the path is not the problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, I am writing code for others to use, so I don't have control over their file-naming convention or the type of geodatabase they are using. &amp;nbsp; &amp;nbsp;If that is the problem, I will need to find a different way to code this check, but it would be nice to know why the Exists function is so inconsistent.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 18:38:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386043#M30456</guid>
      <dc:creator>AllisonBailey</dc:creator>
      <dc:date>2017-09-01T18:38:27Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386044#M30457</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If funky is the default... try 'raw encoding (little r'&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 style="display: block;"&gt;&lt;DIV&gt;&lt;DIV data-linkedid="communications_2_712512_14_2145"&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV data-extendedauthors="false" data-extvisible="false" data-objectid="712512" data-objecttype="2"&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;P&gt;&lt;STRONG&gt;r'Y:\projects\dnr_svmp2016\db\SVMP_2000_2015_DB.v52_20170803\SVMP_DB_v5.2_20170803_AB.mdb\site_samples'&lt;/STRONG&gt;&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;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 18:46:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386044#M30457</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-09-01T18:46:12Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386045#M30458</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sadly, same result -- False when run in script, True when run from interactive window.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 18:50:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386045#M30458</guid>
      <dc:creator>AllisonBailey</dc:creator>
      <dc:date>2017-09-01T18:50:38Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386046#M30459</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Looks like a couple similar (irreproducible) bugs in the past: &amp;nbsp;&lt;A class="link-titled" href="http://support.esri.com/en/Search-Results#search?q=arcpy.Exists&amp;amp;content-type=Bugs" title="http://support.esri.com/en/Search-Results#search?q=arcpy.Exists&amp;amp;content-type=Bugs"&gt;Esri Support Search-Results&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 18:59:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386046#M30459</guid>
      <dc:creator>AllisonBailey</dc:creator>
      <dc:date>2017-09-01T18:59:13Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386047#M30460</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Then try a shorter, cleaner path with the .mdb to rule out a path issue&lt;/P&gt;&lt;P&gt;Then lastly is the use of *.gdb&lt;/P&gt;&lt;P&gt;Then try a different file...&lt;/P&gt;&lt;P&gt;Beyond that you have ruled everything else out&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 19:00:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386047#M30460</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-09-01T19:00:26Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386048#M30461</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I tend to agree that there is a need to move into FileGeodatabases rather than those personal GDB's.&amp;nbsp; Other than that, you can try to join the path and feature class name together instead of raw strings.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Instead of&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;r&lt;SPAN class="string token"&gt;'Y:\projects\dnr_svmp2016\db\SVMP_2000_2015_DB.v52_20170803\SVMP_DB_v5.2_20170803_AB.mdb\site_samples'&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;Try&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; os

gdb &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; r&lt;SPAN class="string token"&gt;'Y:\projects\dnr_svmp2016\db\SVMP_2000_2015_DB.v52_20170803\SVMP_DB_v5.2_20170803_AB.mdb'&lt;/SPAN&gt;
featureclass_name &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; r&lt;SPAN class="string token"&gt;'site_samples'&lt;/SPAN&gt;
featureclass &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; os&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;path&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;join&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;gdb&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; featureclass_name&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;Exists&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;featureclass&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp; 'do stuff&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;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 17:44:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386048#M30461</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2021-12-11T17:44:36Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386049#M30462</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks James and Dan. &amp;nbsp;I used os.path.join in my original code, but was just testing with the raw strings to make it more explicit what was happening.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Turns out it does work correctly with tables in a file geodatabase, regardless of the "funkiness" of the path. &amp;nbsp; &amp;nbsp;I'm still&amp;nbsp;bothered by&amp;nbsp;the fact that the same code&amp;nbsp;works correctly in the interactive window correctly, but not in my script. &amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My IDE is using&amp;nbsp;C:\Python27\ArcGISx6410.4\python.exe to run the script, so that looks like the right version to me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Guess I'll work with ListTables instead and check against the list.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 19:44:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386049#M30462</guid>
      <dc:creator>AllisonBailey</dc:creator>
      <dc:date>2017-09-01T19:44:36Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386050#M30463</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The path to your IDE answers the question.&amp;nbsp; Personal geodatabases are not supported with 64-bit Background Geoprocessing, which is the Python distribution your IDE is using.&amp;nbsp; When running from within ArcMap, it is likely executing in-process, which means it is using 32-bit ArcPy and hence works still with personal geodatabases.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Trying changing your IDE to point to the 32-bit Python distribution that comes with ArcMap.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 19:48:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386050#M30463</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2017-09-01T19:48:10Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386051#M30464</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ah ha! &amp;nbsp; Thank you Joshua! &amp;nbsp; That solved it. &amp;nbsp;&amp;nbsp;Really helpful info.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, that explains why similar code I wrote (using arcpy.Exists) for the Validator of the Toolbox worked and this code didn't. &amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't remember changing/updating the interpreter in PyCharm -- it may have happened when I upgraded recently without me realizing it. &amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Sep 2017 20:01:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386051#M30464</guid>
      <dc:creator>AllisonBailey</dc:creator>
      <dc:date>2017-09-01T20:01:12Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386052#M30465</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;grief&amp;nbsp;&lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/confused.png" /&gt; python interpreters... why doesn't everything move to Anaconda and python 3.x&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 02 Sep 2017 02:22:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386052#M30465</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-09-02T02:22:10Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386053#M30466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I firmly believe 10.6 will stay with Python 2.x, which opens the door to ArcMap never going to 3.x.&amp;nbsp; Pro is getting closer, but we still have too many workflows that can't be migrated cleanly between ArcMap to Pro, thus slowing the adopting of Pro in the organization.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 02 Sep 2017 23:48:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386053#M30466</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2017-09-02T23:48:02Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386054#M30467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Like Y2K ... I still have Cobol friends making a living &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/wink.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.esri.com/thread/177766-python-27-countdown"&gt;Python countdown&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 02 Sep 2017 23:50:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386054#M30467</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2017-09-02T23:50:05Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Exists working in interactive window but not stand-alone script</title>
      <link>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386055#M30468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Totally unrelated to your question, but a tip that might help in future...&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;When I run from the interactive window, I just remove the print statement.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;I use a small function in every script (actually, in a custom utils.py that I have many utils) that I can use for either the interactive window or a script, without having to change print to arcpy.AddMessage&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;def&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;myMsgs&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;message&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;AddMessage&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;message&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;message&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;

myMsgs&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"my message here, with {0} formatiing if needed"&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;"fancy"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&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;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a version that will add the date/time to the message, but that takes a few more steps.&amp;nbsp; This is handy if switching between, especially when developing/debugging. just an fyi.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 17:44:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcpy-exists-working-in-interactive-window-but-not/m-p/386055#M30468</guid>
      <dc:creator>RebeccaStrauch__GISP</dc:creator>
      <dc:date>2021-12-11T17:44:38Z</dc:date>
    </item>
  </channel>
</rss>

