A child of PDOStatement with some extra methods

package salt\sql

 Methods

Retrieve all objects from executed statement

getAllAs(\salt\Base $bindingObject, mixed $indexedBy = NULL) : array<mixed,\salt\Base>

Parameters

$bindingObject

\salt\Base

The type of object to return

$indexedBy

mixed

Column name to use for index array

Returns

array<mixed,\salt\Base>all rows as Base objects

Retrieve next object from executed statement

getAs(\salt\Base $bindingObject) : \salt\Base | FALSE

Parameters

$bindingObject

\salt\Base

The type of object to return

Returns

\salt\BaseFALSEthe next row as Base object or FALSE if there is no more rows

Retrieve all column names

getColumns(array<mixed,string> $excepts = array()) : array<mixed,string>

Parameters

$excepts

array<mixed,string>

do not return theses columns

Returns

array<mixed,string>Column names

Construct a new SqlStatement

__construct()