<?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: ArcGIS Pro 2.1 - How to calculate Null values in a date field in shapefile? in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722784#M55976</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Fount it! The statment is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;return None&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with no single quotes!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 18 May 2018 13:42:17 GMT</pubDate>
    <dc:creator>VincentLaunstorfer</dc:creator>
    <dc:date>2018-05-18T13:42:17Z</dc:date>
    <item>
      <title>ArcGIS Pro 2.1 - How to calculate Null values in a date field in shapefile?</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722781#M55973</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In a model, after joining a shapefile to a text file, I am trying to calculate a newly created Date format field in the shapefile. But, whenever I have an empty date in the text file, the if else statment catches it and tries to fill a Null value in the Date field. But it crashes and not not work!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried:&lt;/P&gt;&lt;P&gt;return ''&lt;/P&gt;&lt;P&gt;return 'None'&lt;/P&gt;&lt;P&gt;return 'Null'&lt;/P&gt;&lt;P&gt;return '0'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But none worked! Any guess for the proper syntax? Thanks&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/406787_Date_Field.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 May 2018 12:34:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722781#M55973</guid>
      <dc:creator>VincentLaunstorfer</dc:creator>
      <dc:date>2018-05-17T12:34:01Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Pro 2.1 - How to calculate Null values in a date field in shapefile?</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722782#M55974</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;you have a code block but no field calculator expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Addendum&amp;nbsp; Shapefiles don't support None, you will have to check for the empty string "" or ''&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 May 2018 22:46:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722782#M55974</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2018-05-17T22:46:01Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Pro 2.1 - How to calculate Null values in a date field in shapefile?</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722783#M55975</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Tried "" or '' but still no luck! Tested it on shapefile and FGDB feature class as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As for the field calculator expression, it looks empty but actually it is not. It always does not show for no reason.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem comes from the None or Null format in the date field because if I set any date instead, it does work. Also, it works in former ArcToolbox. Is it related to Python 3 ? There must be a solution...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 May 2018 13:10:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722783#M55975</guid>
      <dc:creator>VincentLaunstorfer</dc:creator>
      <dc:date>2018-05-18T13:10:45Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Pro 2.1 - How to calculate Null values in a date field in shapefile?</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722784#M55976</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Fount it! The statment is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;return None&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with no single quotes!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 May 2018 13:42:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-pro-2-1-how-to-calculate-null-values-in-a/m-p/722784#M55976</guid>
      <dc:creator>VincentLaunstorfer</dc:creator>
      <dc:date>2018-05-18T13:42:17Z</dc:date>
    </item>
  </channel>
</rss>

