예제 #1
0
파일: Db.php 프로젝트: hitechdk/Codeception
 protected function proceedSeeInDatabase($table, $column, $criteria)
 {
     $query = $this->driver->select($column, $table, $criteria);
     $this->debugSection('Query', $query, json_encode($criteria));
     $sth = $this->driver->executeQuery($query, array_values($criteria));
     return $sth->fetchColumn();
 }
예제 #2
0
파일: Db.php 프로젝트: namnv609/Codeception
 protected function proceedSeeInDatabase($table, $column, $criteria)
 {
     $query = $this->driver->select($column, $table, $criteria);
     $this->debugSection('Query', $query, json_encode($criteria));
     $sth = $this->driver->getDbh()->prepare($query);
     if (!$sth) {
         $this->fail("Query '{$query}' can't be executed.");
     }
     $sth->execute(array_values($criteria));
     return $sth->fetchColumn();
 }
예제 #3
0
 protected function proceedSeeInDatabase($table, $column, $criteria)
 {
     $query = $this->driver->select($column, $table, $criteria);
     $parameters = array_values($criteria);
     $this->debugSection('Query', $query);
     if (!empty($parameters)) {
         $this->debugSection('Parameters', $parameters);
     }
     $sth = $this->driver->executeQuery($query, $parameters);
     return $sth->fetchColumn();
 }