<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to 427: Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/" rel="alternate"/><link href="https://sourceforge.net/p/openemr/bugs/427/feed.atom" rel="self"/><id>https://sourceforge.net/p/openemr/bugs/427/</id><updated>2016-06-17T03:43:15.568000Z</updated><subtitle>Recent changes to 427: Value '0000-00-00' is not valid for MySQL data type DATE</subtitle><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#abb1" rel="alternate"/><published>2016-06-17T03:43:15.568000Z</published><updated>2016-06-17T03:43:15.568000Z</updated><author><name>Brady Miller</name><uri>https://sourceforge.net/u/bradymiller/</uri></author><id>https://sourceforge.net2aa9456941b98213ed36e82f914e488baa1a98db</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;This bug is being discussed in the following thread:&lt;br/&gt;
&lt;a href="https://sourceforge.net/p/openemr/discussion/202506/thread/55600ab2/"&gt;https://sourceforge.net/p/openemr/discussion/202506/thread/55600ab2/&lt;/a&gt;&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#c7c3" rel="alternate"/><published>2016-06-14T00:12:30.612000Z</published><updated>2016-06-14T00:12:30.612000Z</updated><author><name>Daniel Pflieger</name><uri>https://sourceforge.net/u/growlingflea/</uri></author><id>https://sourceforge.neted55bf863eddfa1142f69771963551b17b9b4148</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I am thinking that Oleg has the best idea.  If there is no disagreement, we can go ahead and make these changes and have them submitted to the community.  Are there any objections or unforseen problems that haven't been mentioned?&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#d9d6" rel="alternate"/><published>2016-05-16T11:49:45.937000Z</published><updated>2016-05-16T11:49:45.937000Z</updated><author><name>Oleg Sverdlov</name><uri>https://sourceforge.net/u/osverdlov/</uri></author><id>https://sourceforge.nete5c8d1e00f9662ce2ec4e7d9156d703fca2cccff</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I belive that for the tables: amendments, amendments_history, batchcom we can replace 0000-00-00 with CURRENT_TIMESTAMP without touching the code.&lt;/p&gt;
&lt;p&gt;insurance_data will require a small fix in the code.&lt;/p&gt;
&lt;p&gt;drugs and drug_inventory will require a fix. &lt;/p&gt;
&lt;p&gt;Replacing zeros in openemr_postcalendar_events requires a fix.&lt;/p&gt;
&lt;p&gt;There's an INSERT INTO &lt;code&gt;automatic_notification&lt;/code&gt; clause that needs to be changed as well.&lt;/p&gt;
&lt;p&gt;example_patient_data needs to be changed.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#d029" rel="alternate"/><published>2016-05-16T11:14:30.770000Z</published><updated>2016-05-16T11:14:30.770000Z</updated><author><name>Kevin Yeh</name><uri>https://sourceforge.net/u/yehster/</uri></author><id>https://sourceforge.netc815e186c3f48d4b5d4898a8464f1ea2bf334e00</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;The NO_ZERO_DATE was deprecated in MySQL 5.6 and does nothing in 5.7.&lt;br/&gt;
&lt;/p&gt;
&lt;p&gt;If true support for transactions is a requirement (compatibility with STRICT_TRANS_MODE=on)&lt;br/&gt;
, then references to 0000-00-00 would need to be addressed.  Either by switching to TIMESTAMP or by using a different default value.  How the calendar would treat 1000-01-01 is not something I'm sure about, and there are probably other instances where dates are used with 0000-00-00 that aren't just for the calendar.&lt;/p&gt;
&lt;p&gt;There are many other instances throughout the codebase that are incompatible with strict transaction that would need to be addressed which would require thorough analysis and testing.  TEXT NOT NULL columns is an issue I vaguely remember encountering in the past when experimenting with strict transactions.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#59e1" rel="alternate"/><published>2016-05-16T10:13:02.024000Z</published><updated>2016-05-16T10:13:02.024000Z</updated><author><name>Oleg Sverdlov</name><uri>https://sourceforge.net/u/osverdlov/</uri></author><id>https://sourceforge.net388c5f4544cd658c0e65bab70b0e12b773a246de</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Group&lt;/strong&gt;: Release_4.2.1 --&amp;gt; Development_Release&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</summary></entry><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#5b48" rel="alternate"/><published>2016-05-02T05:51:42.507000Z</published><updated>2016-05-02T05:51:42.507000Z</updated><author><name>Brady Miller</name><uri>https://sourceforge.net/u/bradymiller/</uri></author><id>https://sourceforge.net29faaad96b8e297ab0d5540d0bd423da2763e68d</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Some info on this here:&lt;br/&gt;
&lt;a href="http://dev.mysql.com/doc/refman/5.7/en/sql-mode.html" rel="nofollow"&gt;http://dev.mysql.com/doc/refman/5.7/en/sql-mode.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Note this has been indirectly addressed in the most recent codebase where sql_mode is set to '' explicitly in OpenEMR:&lt;br/&gt;
&lt;a href="https://github.com/openemr/openemr/commit/e7aa71059534321b660eaa9a8e5fda994914c574" rel="nofollow"&gt;https://github.com/openemr/openemr/commit/e7aa71059534321b660eaa9a8e5fda994914c574&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;-brady&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#427 Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/?limit=25#12c2" rel="alternate"/><published>2016-05-02T05:47:37.527000Z</published><updated>2016-05-02T05:47:37.527000Z</updated><author><name>Rod Roark</name><uri>https://sourceforge.net/u/sunsetsystems/</uri></author><id>https://sourceforge.netedd15e2820affc6927055e9367105c3ef74dccfb</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I believe that whether 0000-00-00 is allowed is a MySQL option.  See the documentation for your MySQL version regarding NO_ZERO_DATE and perhaps also "strict mode".  It's likely a matter of updating my.ini (Windows) or my.cnf (*nix).&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/" rel="alternate"/><published>2016-05-02T05:06:58.697000Z</published><updated>2016-05-02T05:06:58.697000Z</updated><author><name>Wahyudi Arifandi</name><uri>https://sourceforge.net/u/arifiswise/</uri></author><id>https://sourceforge.net0b0f31caf2b839100520da23763570480bbe0909</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Following sql are not valid:&lt;br/&gt;
  openemr/sql/2_8_2-to-2_8_3_upgrade.sql (1 hit)&lt;br/&gt;
    Line 116:   MODIFY &lt;code&gt;date&lt;/code&gt; date NOT NULL DEFAULT '0000-00-00',&lt;br/&gt;
  openemr/sq/database.sql (5 hits)&lt;br/&gt;
    Line 950:   &lt;code&gt;last_notify&lt;/code&gt; date NOT NULL default '0000-00-00',&lt;br/&gt;
    Line 1015:   &lt;code&gt;last_notify&lt;/code&gt; date NOT NULL default '0000-00-00',&lt;br/&gt;
    Line 2506:   &lt;code&gt;date&lt;/code&gt; date NOT NULL default '0000-00-00',&lt;br/&gt;
    Line 4785:   &lt;code&gt;pc_eventDate&lt;/code&gt; date NOT NULL default '0000-00-00',&lt;br/&gt;
    Line 4786:   &lt;code&gt;pc_endDate&lt;/code&gt; date NOT NULL default '0000-00-00',&lt;/p&gt;
&lt;p&gt;Date value '0000-00-00' does not work in MySQL 5.5.49-win32.&lt;br/&gt;
 It could be fixed by modifying them into '1000-01-01' as min date for MySQL.&lt;br/&gt;
 If keep using '0000-00-00', then change the data type become TIMESTAMP insteda of DATE&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Value '0000-00-00' is not valid for MySQL data type DATE</title><link href="https://sourceforge.net/p/openemr/bugs/427/" rel="alternate"/><published>2016-05-02T05:06:58.697000Z</published><updated>2016-05-02T05:06:58.697000Z</updated><author><name>Wahyudi Arifandi</name><uri>https://sourceforge.net/u/arifiswise/</uri></author><id>https://sourceforge.net06d408caaefa68f4c0801e6ffceab1ceedb7a74b</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Ticket 427 has been modified: Value '0000-00-00' is not valid for MySQL data type DATE&lt;br/&gt;
Edited By: Oleg Sverdlov (osverdlov)&lt;br/&gt;
_milestone updated: u'Release_4.2.1' =&amp;gt; u'Development_Release'&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>