title: DATEADD When Dealing with SmallDateTime Data Type
body: <p>What I'm trying to accomplish is to select all records in a table that were created the previous day - and the record is stored in the table as a 'smalldatetime' so it also includes the time the record was created.</p>
  
  <p><a href="https://i.stack.imgur.com/zPSy3.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zPSy3.jpg" alt="CreatedDateTime"></a></p>
  
  <p>If I used the DATEADD function in my WHERE clause, I am returning no records which I know is incorrect.</p>
  
  <p><code>Appt.CreatedDateTime = DATEADD(DAY, -1, GETDATE())</code></p>
  
  <p>How I can strip off the time stamp to find all records that were created the previous day?</p>
  
  <p>Thanks,</p>