title: Mysql alter table date not null
body: <p>I wish to update my database (with already data in it), and add a column to a table</p>
  
  <p>This new column is a date and I don't want it null nor having a default value.</p>
  
  <p>Since I already have data in the database, mysql won't allow me to insert a not null data, so what I'm trying is to insert a column null possible, insert all my data, then set it to not null like so</p>
  
  <pre><code>ALTER TABLE `Test`.`rct` 
  ADD COLUMN `dte` DATE NULL AFTER `id`;
  
  --Insert logic here, and now every single rows has a value
  
  ALTER TABLE `Test`.`rct` 
  MODIFY `dte` DATE NOT NULL AFTER `id`;
  </code></pre>
  
  <p>But when I do this, I get this error on the:
  Incorrect date value: '0000-00-00' for column</p>
  
  <p>But I check, and recheck, there is no 0000-00-00 value nowhere</p>
  
  <p>So how can I set that column to null without setting it a default value?</p>
  
  <p>Thank you.</p>