title: SQL Server query for date format
body: <p>Suppose if my web service has parameter <code>year</code> with value <code>201718</code> as string. Then in my query, I want to find something in between <code>01-04-2017</code> and <code>31-03-2018</code>. The date is a <code>datetime</code> in the database. In my query I will use something like this </p>
  
  <pre><code>select * 
  from table 
  where date &gt;= '01-04-2017' and date &lt;= '31-03-18'
  </code></pre>
  
  <p>How should I change the format to accept date as '31-03-18'?</p>