title: CakePHP eliminating null results from pagination
body: <p>I've googled around for this, but part of the problem is that I'm not really sure how to concisely describe my problem. I have two relevant models here: Application and Absence. Application belongsTo Absence, Absence hasMany Application. Here's the schema for Application:</p>
  
  <pre><code>CREATE TABLE applications (
      id int unsigned AUTO_INCREMENT PRIMARY KEY,
      user_id int unsigned,
      absence_id int unsigned
  );
  </code></pre>
  
  <p>It's pretty simple. I want to paginate all Absences with an Application from a particular user (I'm doing this in the Absences controller). I can get close with this code:</p>
  
  <p>absences_controller.php:</p>
  
  <pre><code>$this-&gt;paginate = array(
      'contain' =&gt; array(
          'Application' =&gt; array(
              'conditions' =&gt; array(
                  'Application.user_id' =&gt; $viewer_id,
                  //'NOT' =&gt; array('Application.id' =&gt; null),
              )
          ),
      )
  );
  $this-&gt;set('absences', $this-&gt;paginate());
  </code></pre>
  
  <p>This does return the Absences I want, but it also returns all Absences that have no Application associated with them. Is there a way to do this without custom queries? I'd like to keep my app Cakey. You can see one of my attempts to strip the null Application results in the commented-out 'NOT' line in the code.</p>
  
  <p>Thanks!</p>