title: SQL - Conversion failed when converting date and/or time from character string
body: <p>I have 3 tables in the database that I'm working on. Out of 3, two of the tables have columns that include dates. When I checked the information schema of the columns I found that dates have the wrong data type. If you see the picture below, the highlighted columns should be stored as <code>DATE</code> data type.</p>
  <p><a href="https://i.stack.imgur.com/TqSmU.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TqSmU.png" alt="enter image description here" /></a></p>
  <p>So, I used the following query to change their data type from <code>varchar</code> to <code>DATE</code>:</p>
  <pre><code>ALTER TABLE [dbo].[Customer]
  ALTER COLUMN DOB DATE;
  
  ALTER TABLE [dbo].[Transactions]
  ALTER COLUMN tran_date DATE;
  </code></pre>
  <p>The error that I get is:</p>
  <blockquote>
  <p>Conversion failed when converting date and/or time from character string.</p>
  </blockquote>
  <p>Please let me know how I can fix this error. Thanks!</p>