title: PDO Delete Statement Issue
body: <p>I am having trouble with a delete statement. Some of my code is borrowed and its probably a simple mistake but i cannot figure it out. Im still learning so its probably not too efficient but i want to try and get it working to have a base to work from before i start refining my code more.</p>
  
  <pre><code>public function delete_data($id,$table){
  
      $sql = 'DELETE FROM `'.$table.'` WHERE `my_id` = :id';
      $this-&gt;prepare_qry($sql);
      $this-&gt;bind(':id',$id);
      $this-&gt;execute;
  
      $statement = print_r($this-&gt;stmt,true);
      echo "statement:" . $statement;
  }
  </code></pre>
  
  <p>When i echo out this i get:</p>
  
  <pre><code>DELETE FROM `my_table` WHERE `my_id` = :id
  </code></pre>
  
  <p>So that looks fine. Here are some of the relevant functions also</p>
  
  <pre><code>// Create a new PDO instanace
  try{
      $this-&gt;dbh = new PDO($dsn, $this-&gt;user, $this-&gt;pass, $options);
      } catch(PDOException $e){ // Catch any errors
      $this-&gt;error = $e-&gt;getMessage();
  }
  
  // prepare the query
  public function prepare_qry($query){
  $this-&gt;stmt = $this-&gt;dbh-&gt;prepare($query);
  }
  
  // add the type for the binding
  public function bind($param, $value, $type = null){
  if (is_null($type)) {
  switch (true) {
          case is_int($value):
      $type = PDO::PARAM_INT;
      break;
  
          case is_bool($value):
      $type = PDO::PARAM_BOOL;
      break;
  
          case is_null($value):
      $type = PDO::PARAM_NULL;
      break;
  
          default:
      $type = PDO::PARAM_STR;
  }
  }
  // run the binding process
  $this-&gt;stmt-&gt;bindValue($param, $value, $type);
  }
  
  // execute query
  public function execute(){
      return $this-&gt;stmt-&gt;execute();
  }
  </code></pre>
  
  <p>When run the code i get the following error. Any ideas what the problem is:</p>
  
  <pre><code>Undefined property: Database::$execute
  </code></pre>