Public Method Details |
DB_mysql |
public void DB_mysql( )
|
|
DB_mysql constructor.
|
Returns |
void |
|
connect |
public int connect( &$dsn, boolean $persistent )
|
|
Connect to a database and log in as the specified user.
|
Parameter |
|
|
&$dsn |
|
|
Warning: documentation is missing. |
|
|
boolean |
$persistent |
|
|
Warning: documentation is missing. |
|
Returns |
int DB_OK on success, a DB error on failure |
|
disconnect |
public bool disconnect( )
|
|
Log out and disconnect from the database.
|
Returns |
bool TRUE on success, FALSE if not connected. |
|
&query |
public object a &query( $query )
|
|
Send a query to MySQL and return the results as a DB_result object.
|
Parameter |
|
|
$query |
|
|
Warning: documentation is missing. |
|
Returns |
object a DB_result object on success, a DB error
on failure |
|
simpleQuery |
public int simpleQuery( $query )
|
|
Send a query to MySQL and return the results as a MySQL resource
identifier.
|
Parameter |
|
|
$query |
|
|
Warning: documentation is missing. |
|
Returns |
int returns a valid MySQL result for successful SELECT
queries, DB_OK for other successful queries. A DB error is
returned on failure. |
|
&fetchRow |
public mixed &fetchRow( array $result, string $fetchmode )
|
|
Fetch a row and return as array.
|
Parameter |
|
|
|
string |
$fetchmode |
|
|
Warning: documentation is missing. |
|
Returns |
mixed an array on success, a DB error on failure, NULL
if there is no more data |
|
fetchInto |
public int fetchInto( array $result, array &$arr, string $fetchmode )
|
|
Fetch a row and insert the data into an existing array.
|
Parameter |
|
array |
$result |
|
|
data from the row is stored |
|
|
array |
&$arr |
|
|
should be indexed |
|
|
string |
$fetchmode |
|
|
Warning: documentation is missing. |
|
Returns |
int DB_OK on success, a DB error on failure |
|
freeResult |
public bool freeResult( $result )
|
|
Free the internal resources associated with $result.
|
Parameter |
|
|
$result |
|
|
Warning: documentation is missing. |
|
Returns |
bool TRUE on success, FALSE if $result is invalid |
|
numCols |
public int numCols( $result )
|
|
Get the number of columns in a result set.
|
Parameter |
|
|
$result |
|
|
Warning: documentation is missing. |
|
Returns |
int the number of columns per row in $result |
|
errorNative |
public int errorNative( )
|
|
Get the native error code of the last error (if any) that
occured on the current connection.
|
Returns |
int native MySQL error code |
|
prepare |
public int prepare( $query )
|
|
Prepares a query for multiple execution with execute(). With
MySQL, this is emulated.
Warning: documentation is missing.
|
Parameter |
|
|
$query |
|
|
Warning: documentation is missing. |
|
Returns |
int identifier for this prepared query |
|
autoCommit |
public object DB autoCommit( boolean $onoff )
|
|
Enable/disable automatic commits [not supported by MySQL]
|
Parameter |
|
boolean |
$onoff |
|
|
Warning: documentation is missing. |
|
Returns |
object DB error code (not capable) |
|
commit |
public object DB commit( )
|
|
Commit transactions on the current connection [not supported by MySQL]
|
Returns |
object DB error code (not capable) |
|
rollback |
public object DB rollback( )
|
|
Roll back all uncommitted transactions on the current connection.
[not supported by MySQL]
|
Returns |
object DB error code (not capable) |
|