title: How to search a date field using wild cards?
body: <p>I have a date search field in my ASP.Net application where the user enters the date he's looking for and the SQL query looks for the exact date provided. </p>
  
  <p>I'm asked to allow the user to enter the date search using wildcards as follows:<br>
  - <code>*/12/2015</code> would mean get all the month of December, 2015<br>
  - <code>*/*/2015</code> would mean get all the year of 2015<br>
  - <code>*/*/*</code> would mean get all the data you got</p>
  
  <p>The only way I could think about to do this is to look in my C# code for '*' in the date, if it exists I will replace the query by a date range based on the position of the <code>*</code>. </p>
  
  <p>This solution doesn't look practical to me, is there an easier way to do it in C# or SQL ?</p>