title: How to parse SQL Server binary date format in mysql?
body: <p>How to convert <code>CAST(0xE3350B00 AS DATE)</code> to <strong>mysql</strong> ?</p>
  
  <p>I used various forum supports and have following results</p>
  
  <pre><code>0xE3350B00 =&gt; 2059-04-03 22:56
  0x0000A17F00000000 =&gt; 2013-03-12
  </code></pre>
  
  <p>But both dates belong to same line of data so i am confident that <code>0xE3350B00</code> should convert to nearby <code>2013-03-12</code> but not finding it technically? Can anyone help if conversion of <code>0xE3350B00</code> date??</p>
  
  <p>I used following code in sql function:</p>
  
  <pre><code>return date_add(date_add("1900-01-01 00:00:00", interval conv(substr(HEX(raw_data), 5, 4), 16, 10) DAY), interval conv(substr(HEX(raw_data), 1, 4), 16, 10) MINUTE);
  </code></pre>