Interface IDibiDriver
dibi driver interface.
| Method Summary | |
|---|---|
| void |
applyLimit
(string &$sql, int $limit, int $offset)
Injects LIMIT/OFFSET to the SQL query.
|
| void |
begin
([string $savepoint =
NULL])
Begins a transaction (if supported).
|
| void |
commit
([string $savepoint =
NULL])
Commits statements in a transaction.
|
| void |
connect
(&$config)
Connects to a database.
|
| void |
disconnect
()
Disconnects from a database.
|
| string |
escape
(string $value, string $type)
Encodes data for use in a SQL statement.
|
| array |
fetch
(bool $type)
Fetches the row at current position and moves the internal cursor to the next position.
|
| void |
free
(resource 0)
Frees the resources allocated for this result set.
|
| int|FALSE |
Gets the number of affected rows by the last INSERT, UPDATE or DELETE query.
|
| array |
getColumns
(string $table)
Returns metadata for all columns in a table.
|
| array |
Returns metadata for all columns in a result set.
|
| array |
getForeignKeys
(string $table)
Returns metadata for all foreign keys in a table.
|
| array |
getIndexes
(string $table)
Returns metadata for all indexes in a table.
|
| int|FALSE |
getInsertId
($sequence)
Retrieves the ID generated for an AUTO_INCREMENT column by the previous INSERT query.
|
| mixed |
getResource
()
Returns the connection resource.
|
| mixed |
Returns the result set resource.
|
| int |
getRowCount
()
Returns the number of rows in a result set.
|
| array |
getTables
()
Returns list of tables.
|
| bool |
Is in transaction?
|
| IDibiDriver|NULL |
query
(string $sql)
Internal: Executes the SQL query.
|
| void |
rollback
([string $savepoint =
NULL])
Rollback changes in a transaction.
|
| boolean |
seek
(int $row)
Moves cursor position without fetching row.
|
| string |
unescape
(string $value, string $type)
Decodes data from result set.
|
| Method Details | |||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
line 191 applyLimitpublic void applyLimit (string &$sql, int $limit, int $offset) Injects LIMIT/OFFSET to the SQL query.
|
|||||||||||||||||||||
|
line 130 beginpublic void begin ([string $savepoint = Begins a transaction (if supported).
|
|||||||||||||||||||||
|
line 138 commitpublic void commit ([string $savepoint = Commits statements in a transaction.
|
|||||||||||||||||||||
|
line 95 connectpublic void connect (&$config) Connects to a database.
|
|||||||||||||||||||||
|
line 102 disconnectpublic void disconnect () Disconnects from a database.
|
|||||||||||||||||||||
|
line 173 escapepublic string escape (string $value, string $type) Encodes data for use in a SQL statement.
|
|||||||||||||||||||||
|
line 219 fetchpublic array fetch (bool $type) Fetches the row at current position and moves the internal cursor to the next position.
|
|||||||||||||||||||||
|
line 226 freepublic void free (resource 0) Frees the resources allocated for this result set.
|
|||||||||||||||||||||
|
line 116 getAffectedRowspublic int|FALSE getAffectedRows () Gets the number of affected rows by the last INSERT, UPDATE or DELETE query.
|
|||||||||||||||||||||
|
line 258 getColumnspublic array getColumns (string $table) Returns metadata for all columns in a table.
|
|||||||||||||||||||||
|
line 233 getColumnsMetapublic array getColumnsMeta () Returns metadata for all columns in a result set.
|
|||||||||||||||||||||
|
line 272 getForeignKeyspublic array getForeignKeys (string $table) Returns metadata for all foreign keys in a table.
|
|||||||||||||||||||||
|
line 265 getIndexespublic array getIndexes (string $table) Returns metadata for all indexes in a table.
|
|||||||||||||||||||||
|
line 122 getInsertIdpublic int|FALSE getInsertId ($sequence) Retrieves the ID generated for an AUTO_INCREMENT column by the previous INSERT query.
|
|||||||||||||||||||||
|
line 158 getResourcepublic mixed getResource () Returns the connection resource. |
|||||||||||||||||||||
|
line 239 getResultResourcepublic mixed getResultResource () Returns the result set resource. |
|||||||||||||||||||||
|
line 203 getRowCountpublic int getRowCount () Returns the number of rows in a result set. |
|||||||||||||||||||||
|
line 251 getTablespublic array getTables () Returns list of tables. |
|||||||||||||||||||||
|
line 152 inTransactionpublic bool inTransaction () Is in transaction? |
|||||||||||||||||||||
|
line 110 querypublic IDibiDriver|NULL query (string $sql) Internal: Executes the SQL query.
|
|||||||||||||||||||||
|
line 146 rollbackpublic void rollback ([string $savepoint = Rollback changes in a transaction.
|
|||||||||||||||||||||
|
line 211 seekpublic boolean seek (int $row) Moves cursor position without fetching row.
|
|||||||||||||||||||||
|
line 182 unescapepublic string unescape (string $value, string $type) Decodes data from result set.
|
|||||||||||||||||||||