title: Conversion failed when converting date and/or time from character string
body: <p>I have this query :</p>
  
  <pre><code>set IDENTITY_INSERT dbo.OtherData1 ON
  
  
  INSERT INTO OtherData1 (OtherDataID, EmployeeID, OtherDate, OType, OSubject, StatementNo, StatementDate, Info, OtherAs, FolderSerial)
  
      SELECT OtherDataID, EmployeeID, 
                   CONVERT(DATE, OtherDate, 103), 
                       OType, OSubject, StatementNo, 
                       CONVERT(DATE, StatementDate), Info,
                       CASE OtherAs
             WHEN  'f' THEN 1
                WHEN  's' THEN 2
                WHEN 't' THEN 3
                WHEN 'f' THEN 4
                WHEN 'p' THEN 5
                WHEN 'o' THEN 6
             ELSE NULL END
             , FolderSerial
      FROM OtherData
  </code></pre>
  
  <p>I when I execute it I get this error :</p>
  
  <pre><code>Msg 241, Level 16, State 1, Line 5
  Conversion failed when converting date and/or time from character string.
  </code></pre>
  
  <p>the values for StatementDate, OtherDate are in this format <strong><code>"31/1/1994"</code></strong> as string before convert</p>
  
  <p>What is the problem?</p>
  
  <p><strong>EDIT</strong>:</p>
  
  <p>if I added this line of code :</p>
  
  <pre><code>CASE WHEN ISDATE(OtherDate) = 1 THEN 
    CONVERT(DATE, OtherDate, 103)
  ELSE NULL END
  </code></pre>
  
  <p>I tried it and it's not working, I need some thing like it to check if vaild do the convert if not insert NULL value and I get the same error message</p>