title: Strange MySQL warning 1264 for valid DateTime value
body: <p>I have manually (GASP!) entered a MySQL command at the command line, and I received a Warning which I cannot even begin to understand.  (And before anyone says anything, yes, I KNOW: 1. Using the command line interface is not the best approach; 2. My table is NOT named "TABLE_NAME" and my column is NOT named "DateColumn" and my RecordID value is NOT really "1234"; 3. Maybe my column type <em>should</em> be TIMESTAMP, but for now, it's not.  Moving on....) </p>
  
  <p>Attempting to enter a value for the date "July 26th, 2012 at 2:27 PM (GMT)", I keyed: </p>
  
  <pre><code>mysql&gt; update TABLE_NAME set DateColumn="2012-07-26 14:27:00" where RecordID="1234";
  </code></pre>
  
  <p>I received: </p>
  
  <pre><code>Query OK, 1 row affected, 1 warning (0.11 sec) 
  Rows matched: 1  Changed: 1  Warnings: 1
  </code></pre>
  
  <p>So, I keyed: </p>
  
  <pre><code>mysql&gt; show warnings;
  +---------+------+-----------------------------------------------------+
  | Level   | Code | Message                                             |
  +---------+------+-----------------------------------------------------+
  | Warning | 1264 | Out of range value for column 'DateColumn' at row 1 |
  +---------+------+-----------------------------------------------------+
  </code></pre>
  
  <p>Weird, I thought.  So I checked the table first to confirm the column (field) type: </p>
  
  <pre><code>mysql&gt; describe TABLE_NAME;
  
  +------------+----------+------+-----+-------------------+-------+
  | Field      | Type     | Null | Key | Default           | Extra |
  | DateColumn | datetime | YES  |     | NULL              |       |
  +------------+----------+------+-----+-------------------+-------+
  </code></pre>
  
  <p>BUT the value DOES get written properly to the database, and not truncated, AFAIK:  </p>
  
  <pre><code>mysql&gt; select * from TABLE_NAME where RecordID="1234";
  
  +-----------------------------------------------+
  | RecordID | Date_Column         | BlahBlahBlah |
  +----------+---------------------+--------------+
  |     1234 | 2012-07-26 14:27:00 | something..  | 
  +----------+---------------------+--------------+
  </code></pre>
  
  <p>I've already searched StackOverflow.com for a solution.  I've already Googled for an explanation.  I've already read up at <a href="http://dev.mysql.com/doc/refman/5.5/en/datetime.html" rel="noreferrer">http://dev.mysql.com/doc/refman/5.5/en/datetime.html</a> where it says:</p>
  
  <pre><code>    MySQL retrieves and displays DATETIME values in 'YYYY-MM-DD HH:MM:SS' format. The supported range is '1000-01-01 00:00:00' to '9999-12-31 23:59:59'. 
  </code></pre>
  
  <p>I even had a slight suspicion that it had something to do with the date or time at which I was making the entry; so I will state that the server on which the database is located is on Pacific Daylight Time (GMT-8, except right now GMT-7 for DST); I am logged in (SSH) from a client on EDT (which should not matter); and I am storing all Date_Column values as GMT.  At the time I was entering the value "2012-07-26 14:27:00" all three dates were well AFTER that, on 7/30/12.  Not that it should matter -- I <em>should</em> be able to enter <em>future</em> dates without getting an error -- but thought it might be helpful for you to know.  So -- </p>
  
  <p><strong>WHY, OH WHY is "2012-07-26 14:27:00" an Out-of-Range Value?</strong>  </p>
  
  <p>My MySQL client API version is 5.1.49.   </p>
  
  <p>This is the first time I've ever posted on StackOverflow.  Thank you in advance for your suggestions. </p>