PDO Interface to implement for database drivers

package Query
subpackage Drivers

 Methods

Constructor/Connection method

__construct(string $dsn, \Query\Driver\[string] $username = NULL, \Query\Driver\[string] $password = NULL, \Query\Driver\[array] $driver_options = array()) : void

Parameters

$dsn

string

$driver_options

\Query\Driver\[array]

Begin a transaction

beginTransaction() : bool

Returns

bool

Commit a transaction

commit() : bool

Returns

bool

Return the current error code

errorCode() : mixed

Returns

mixed

Return information about the current error

errorInfo() : array

Returns

array

Execute an SQL statement and return the number of affected rows

exec(string $statement) : int

Parameters

$statement

string

Returns

int

Get a connection attribute for the current db driver

getAttribute(int $attribute) 
returm mixed

Parameters

$attribute

int

Rollback a transaction

rollback() : bool

Returns

bool

Set a connection attribute

setAttribute(int $attribute, mixed $value) : bool

Parameters

$attribute

int

$value

mixed

Returns

bool