title: Getting null when filter django model by datetime
body: <p>I have imported datetime as <code>import datetime</code></p>
  
  <p>I need to count database values filtered by datetime in my django model as:</p>
  
  <pre><code>def post_left_count(self):
  
          return self.post_set.filter(expiry_date=datetime.datetime(2013, 10, 27)).count()
  </code></pre>
  
  <p>It returns <code>0</code> but it should have returned a value 50 which is my database entries.</p>
  
  <p>If i run this command into my sql shell:</p>
  
  <pre><code>select title , expiry_date from tblpost where expiry_date = '2013-10-27 00:00:00';
  </code></pre>
  
  <p>it results into 50 rows.</p>
  
  <p>I don't know why above function is returning 0 instead of 50?</p>