Connection

Connection

Database Connection Interface Borrowed in part from Illuminate\Database\ConnectionInterface

Methods

getConnection

Get the current PDO connection.

Connection::getConnection( ): \PDO

Return Value: \PDO


selectOne

Run a select statement and return a single result.

Connection::selectOne( string $query, array $bindings = array() ): mixed

Return Value: mixed


select

Run a select statement against the database.

Connection::select( string $query, array $bindings = array() ): array

Return Value: array


insert

Run an insert statement and return the last insert ID.

Connection::insert( string $query, array $bindings = array() ): integer

Return Value: integer


update

Run an update statement against the database.

Connection::update( string $query, array $bindings = array() ): integer

Return Value: integer


delete

Run a delete statement against the database.

Connection::delete( string $query, array $bindings = array() ): integer

Return Value: integer


statement

Execute an SQL statement and return the boolean result.

Connection::statement( string $query, array $bindings = array() ): boolean

Return Value: boolean


affectingStatement

Run an SQL statement and get the number of rows affected.

Connection::affectingStatement( string $query, array $bindings = array() ): integer

Return Value: integer


executeQuery

Connection::executeQuery( array $bindings = array(), string $query ): boolean

Return Value: boolean


Last updated : September 15, 2018 b92362d