DBLibPDO
extends PDO
in package
This is an extension of the default PDO class of DBLIB drivers.
It provides workarounds for improperly implemented functionalities of the DBLIB drivers.
Tags
Table of Contents
Methods
- getAttribute() : mixed
- Retrieve a database connection attribute.
- lastInsertId() : int
- Returns value of the last inserted ID.
Methods
getAttribute()
Retrieve a database connection attribute.
public
getAttribute(int $attribute) : mixed
It is necessary to override PDO's method as some MSSQL PDO driver (e.g. dblib) does not support getting attributes.
Parameters
- $attribute : int
-
One of the PDO::ATTR_* constants.
Attributes
Return values
mixed —A successful call returns the value of the requested PDO attribute. An unsuccessful call returns null.
lastInsertId()
Returns value of the last inserted ID.
public
lastInsertId([string|null $name = null ]) : int
Parameters
- $name : string|null = null
-
the sequence name. Defaults to null.
Attributes
Return values
int —last inserted ID value.