title: How to validate if a DateTime includes time in SQL Server
body: <p>I have a stored procedure that takes a <code>datetime</code> parameter. I need to determine if the given <code>datetime</code> parameter includes the time.</p>
  
  <p>Now, <code>DATEPART(hour, @datetimeValue) = 0</code> doesn't work in my case because the datetime can be provided as <code>3/14/2019 0:00</code> which refers to as 12 AM and valid.</p>
  
  <p>Return true if input is :</p>
  
  <pre><code>'3/14/2019 0:00'
  '3/14/2019 15:00'
  </code></pre>
  
  <p>Return false only if input has no time :</p>
  
  <pre><code>'3/14/2019'
  </code></pre>
  
  <p>Thanks everyone for their input. It looks there is no solution to this other than changing the stored procedure parameter to <code>varchar</code>.</p>