19 declare(strict_types=1);
32 public function __construct(
protected \PDOStatement $pdo_statement)
44 return $this->pdo_statement->fetch(PDO::FETCH_ASSOC);
48 return $this->pdo_statement->fetch(PDO::FETCH_OBJ);
51 throw new ilDatabaseException(
"No valid fetch mode given, choose ilDBConstants::FETCHMODE_ASSOC or ilDBConstants::FETCHMODE_OBJECT");
69 $this->pdo_statement->closeCursor();
75 return $this->pdo_statement->rowCount();
93 return $this->pdo_statement->rowCount();
99 $this->pdo_statement->execute($a_data);
106 return $this->pdo_statement->errorCode();
111 return $this->pdo_statement->errorInfo();
fetch(int $fetch_mode=ilDBConstants::FETCHMODE_ASSOC)
Class ilPDOStatement is a Wrapper Class for PDOStatement.
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
closeCursor()
Pdo allows for a manual closing of the cursor.
execute(?array $a_data=null)
__construct(protected \PDOStatement $pdo_statement)
fetchRow(int $fetch_mode=ilDBConstants::FETCHMODE_ASSOC)