MediaWiki
REL1_24
|
Public Member Functions | |
__construct () | |
query ($sql, $fname= '', $tempIgnore=false) | |
Run an SQL query and return the result. | |
replaceVars ($s) | |
Override parent visibility to public. | |
Private Attributes | |
$lastQuery |
Definition at line 3 of file DatabaseSqliteTest.php.
Definition at line 6 of file DatabaseSqliteTest.php.
MockDatabaseSqlite::query | ( | $ | sql, |
$ | fname = '' , |
||
$ | tempIgnore = false |
||
) |
Run an SQL query and return the result.
Normally throws a DBQueryError on failure. If errors are ignored, returns false instead.
In new code, the query wrappers select(), insert(), update(), delete(), etc. should be used where possible, since they give much better DBMS independence and automatically quote or validate user input in a variety of contexts. This function is generally only useful for queries which are explicitly DBMS-dependent and are unsupported by the query wrappers, such as CREATE TABLE.
However, the query wrappers themselves should call this function.
string | $sql | SQL query |
string | $fname | Name of the calling function, for profiling/SHOW PROCESSLIST comment (you can use __METHOD__ or add some extra info) |
bool | $tempIgnore | Whether to avoid throwing an exception on errors... maybe best to catch the exception instead? |
MWException |
Reimplemented from DatabaseBase.
Definition at line 10 of file DatabaseSqliteTest.php.
References DatabaseBase\lastQuery().
Referenced by DatabaseSqliteTest\getColumns(), DatabaseSqliteTest\getIndexes(), and DatabaseSqliteTest\testCaseInsensitiveLike().
Override parent visibility to public.
Reimplemented from DatabaseSqlite.
Definition at line 19 of file DatabaseSqliteTest.php.
References $s.
MockDatabaseSqlite::$lastQuery [private] |
Definition at line 4 of file DatabaseSqliteTest.php.