title: PDO: Invalid parameter number: parameter was not defined
body: <p>I can't find the error in my code. I'm trying to fetch the results in an array. The SQL query is correct, I tried it in my PHPMYADMIN. <code>$team</code> is an interger.</p>
  
  <p>What did I do wrong? I am very new to PDO.</p>
  
  <p>EDIT: paramater dumps</p>
  
  <pre><code>SQL: [207] select a.start, a.end, a.type_FK, a.absences_ID, employee_FK, e.surname, e.name, e.cts from employee e JOIN absences a ON e.employee_ID=a.employee_FK WHERE approved = 0 and team_FK = :team order by start ASC Params: 1 Key: Name: [5] :team paramno=-1 name=[5] ":team" is_param=1 param_type=2
  
  
  $sql = "select a.start, a.end, a.type_FK, a.absences_ID, employee_FK, e.surname, e.name, e.cts from employee e JOIN absences a ON e.employee_ID=a.employee_FK WHERE approved = 0 and team_FK = :team order by start ASC";
      $stmt = $db-&gt;prepare($sql);
      $stmt-&gt;execute(array(':team' =&gt; $team));
      $unapproved = $stmt-&gt;fetchAll();
  </code></pre>