|
XOOPS 2.5.6
Final
|

Public Member Functions | |
| close () | |
| connect ($selectdb=TRUE) | |
| errno () | |
| error () | |
| fetchArray ($result) | |
| fetchBoth ($result) | |
| fetchObject ($result) | |
| fetchRow ($result) | |
| freeRecordSet ($result) | |
| genId ($sequence) | |
| getAffectedRows () | |
| getFieldName ($result, $offset) | |
| getFieldsNum ($result) | |
| getFieldType ($result, $offset) | |
| getInsertId () | |
| getRowsNum ($result) | |
| query ($sql, $limit=0, $start=0) | |
| queryF ($sql, $limit=0, $start=0) | |
| queryFromFile ($file) | |
| quote ($string) | |
| quoteString ($str) | |
Public Member Functions inherited from XoopsDatabase | |
| prefix ($tablename= '') | |
| setLogger (&$logger) | |
| setPrefix ($value) | |
| XoopsDatabase () | |
Public Attributes | |
| $conn | |
Public Attributes inherited from XoopsDatabase | |
| $allowWebChanges = false | |
| $logger | |
| $prefix = '' | |
Definition at line 44 of file mysqldatabase.php.
| XoopsMySQLDatabase::close | ( | ) |
Close MySQL connection
Definition at line 184 of file mysqldatabase.php.
| XoopsMySQLDatabase::connect | ( | $selectdb = TRUE | ) |
connect to the database
| bool | $selectdb | select the database now? |
Definition at line 59 of file mysqldatabase.php.
References $_SERVER, XOOPS_DB_CHARSET, XOOPS_DB_HOST, XOOPS_DB_NAME, XOOPS_DB_PASS, XOOPS_DB_PCONNECT, and XOOPS_DB_USER.
| XoopsMySQLDatabase::errno | ( | ) |
Returns the numerical value of the error message from previous MySQL operation
Definition at line 215 of file mysqldatabase.php.
| XoopsMySQLDatabase::error | ( | ) |
Returns the text of the error message from previous MySQL operation
Definition at line 205 of file mysqldatabase.php.
| XoopsMySQLDatabase::fetchArray | ( | $result | ) |
Fetch a result row as an associative array
Definition at line 124 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::fetchBoth | ( | $result | ) |
Fetch a result row as an associative array
Definition at line 134 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::fetchObject | ( | $result | ) |
XoopsMySQLDatabase::fetchObjected()
| mixed | $result |
Definition at line 145 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::fetchRow | ( | $result | ) |
Get a result row as an enumerated array
| resource | $result |
Definition at line 114 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::freeRecordSet | ( | $result | ) |
will free all memory associated with the result identifier result.
| resource | $ query result |
Definition at line 195 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::genId | ( | $sequence | ) |
generate an ID for a new row
This is for compatibility only. Will always return 0, because MySQL supports autoincrement for primary keys.
| string | $sequence | name of the sequence from which to get the next ID |
Definition at line 103 of file mysqldatabase.php.
| XoopsMySQLDatabase::getAffectedRows | ( | ) |
| XoopsMySQLDatabase::getFieldName | ( | $result, | |
| $offset | |||
| ) |
Get field name
| resource | $result | query result |
| int | $ numerical field index |
Definition at line 316 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::getFieldsNum | ( | $result | ) |
Get number of fields in result
| resource | $result | query result |
Definition at line 339 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::getFieldType | ( | $result, | |
| $offset | |||
| ) |
Get field type
| resource | $result | query result |
| int | $offset | numerical field index |
Definition at line 328 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::getInsertId | ( | ) |
Get the ID generated from the previous INSERT operation
Definition at line 155 of file mysqldatabase.php.
| XoopsMySQLDatabase::getRowsNum | ( | $result | ) |
Get number of rows in result
| resource | $ query result |
Definition at line 166 of file mysqldatabase.php.
References $result.
| XoopsMySQLDatabase::query | ( | $sql, | |
$limit = 0, |
|||
$start = 0 |
|||
| ) |
perform a query
This method is empty and does nothing! It should therefore only be used if nothing is exactly what you want done! ;-)
| string | $sql | a valid MySQL query |
| int | $limit | number of records to return |
| int | $start | offset of first record to return |
Definition at line 280 of file mysqldatabase.php.
| XoopsMySQLDatabase::queryF | ( | $sql, | |
$limit = 0, |
|||
$start = 0 |
|||
| ) |
perform a query on the database
| string | $sql | a valid MySQL query |
| int | $limit | number of records to return |
| int | $start | offset of first record to return |
Definition at line 248 of file mysqldatabase.php.
References $limit, $result, $sql, and $start.
Referenced by XoopsMySQLDatabaseSafe\query(), and XoopsMySQLDatabaseProxy\query().

| XoopsMySQLDatabase::queryFromFile | ( | $file | ) |
perform queries from SQL dump file in a batch
| string | $file | file path to an SQL dump file |
Definition at line 290 of file mysqldatabase.php.
References $file, $query, SqlUtility\prefixQuery(), and SqlUtility\splitMySqlFile().

| XoopsMySQLDatabase::quote | ( | $string | ) |
Quotes a string for use in a query.
Definition at line 234 of file mysqldatabase.php.
| XoopsMySQLDatabase::quoteString | ( | $str | ) |
Returns escaped string text with single quotes around it to be safely stored in database
| string | $str | unescaped string text |
Definition at line 226 of file mysqldatabase.php.
| XoopsMySQLDatabase::$conn |
Definition at line 51 of file mysqldatabase.php.