title: SQL Server create date
body: <p>Can we create a date using SQL Server 2005 ?</p>
  
  <p>Example if I have year = 2010, month = 11, and day = 2, how can I convert or create it to datetime?</p>
  
  <p>Below is if we write it in javascript</p>
  
  <pre><code>var date = new Date(2010, 10, 2, 0, 0, 0, 0);
  </code></pre>
  
  <p>and this is with oracle</p>
  
  <pre><code>SELECT TO_DATE('2010-11-02', 'YYYY-MM-DD') FROM DUAL
  </code></pre>
  
  <p>Thank you</p>