title: Cakephp check if record exists
body: <p>I am wondering, is there a function that allows me to check instantly if a record in the database exists?</p>
  
  <p>Right now I am using the following piece of code to detect if a record exists, but I can imagine there is a simpler/better way.</p>
  
  <pre><code>$conditions = array(
      'conditions' =&gt; array(
           'User.id' =&gt; $this-&gt;Session-&gt;read('User.id'),
           'User.activation_key' =&gt; $this-&gt;Session-&gt;read('User.key')
       )
  );
  $result = $this-&gt;User-&gt;find('first', $conditions);
  if (isset($result['User'])){
      //do something
  }
  </code></pre>
  
  <p>Is there something like:</p>
  
  <pre><code>$conditions = array(
      'conditions' =&gt; array(
           'User.id' =&gt; $this-&gt;Session-&gt;read('User.id'),
           'User.security_key' =&gt; $this-&gt;Session-&gt;read('User.key')
      )
  );
  if ($this-&gt;User-&gt;exists($conditions)){
      //do something
  }
  </code></pre>
  
  <p>Okay, yes there is. It's called <code>exists()</code>, but I need the same, but with parameters, so I can add my own conditions to the check.</p>
  
  <p>I have searched google, but I can't find any topic about this. Well, a lot about php and mysql, but not about cakephp. I need a cake specific answer. </p>
  
  <p>Thanks for your time :)</p>