DbiExtension
interface DbiExtension (View source)
Contract for every database extension supported by phpMyAdmin
Methods
runs a query and returns the result
returns a string that represents the client library version
Returns last error message or an empty string if no errors occurred.
Returns the error code for the most recent connection attempt.
returns properly escaped string for use in MySQL queries
Execute a prepared statement and return the result.
Details
Connection
connect(Server $server)
Connects to the database server.
bool
selectDb(DatabaseName $databaseName, Connection $connection)
selects given database
ResultInterface|false
realQuery(string $query, Connection $connection, bool $unbuffered = false)
runs a query and returns the result
bool
realMultiQuery(Connection $connection, string $query)
Run the multi query and output the results
bool
nextResult(Connection $connection)
Prepare next result from multi_query
ResultInterface|false
storeResult(Connection $connection)
Store the result returned from multi query
string
getHostInfo(Connection $connection)
Returns a string representing the type of connection used
string
getClientInfo()
returns a string that represents the client library version
string
getError(Connection $connection)
Returns last error message or an empty string if no errors occurred.
int
getConnectionErrorNumber()
Returns the error code for the most recent connection attempt.
int|string
affectedRows(Connection $connection)
returns the number of rows affected by last query
string
escapeString(Connection $connection, string $string)
returns properly escaped string for use in MySQL queries
ResultInterface|null
executeQuery(Connection $connection, string $query, array $params)
Execute a prepared statement and return the result.
int
getWarningCount(Connection $connection)
Returns the number of warnings from the last query.