Sql
class Sql (View source)
Set of functions for the SQL executor
Properties
| static bool|null | $showAsPhp | ||
| static Message|null | $usingBookmarkMessage |
Methods
No description
Get the HTML for relational column dropdown During grid edit, if we have a relational field, returns the html for the dropdown
Get value of a column for a specific row (marked by $whereClause)
Get all the values for a enum column or set column in a table
Function to check whether this query is for just browsing
No description
Function to get the default sql query for browsing page
Function to store the query as a bookmark
Function to execute the query and send the response
Function to execute the query and send the response
Details
__construct(DatabaseInterface $dbi, Relation $relation, RelationCleanup $relationCleanup, Transformations $transformations, Template $template, BookmarkRepository $bookmarkRepository, Config $config, ResponseRenderer $responseRenderer)
No description
string
getHtmlForRelationalColumnDropdown(string $db, string $table, string $column, string $currentValue, string $currentValueParam)
Get the HTML for relational column dropdown During grid edit, if we have a relational field, returns the html for the dropdown
string
getFullValuesForSetColumn(string $db, string $table, string $column, string $whereClause)
Get value of a column for a specific row (marked by $whereClause)
array|null
getValuesForColumn(string $db, string $table, string $columnName)
Get all the values for a enum column or set column in a table
static bool
isJustBrowsing(StatementInfo $statementInfo, bool $findRealEnd = false)
Function to check whether this query is for just browsing
bool
hasNoRightsToDropDatabase(StatementInfo $statementInfo)
No description
string
getDefaultSqlQueryForBrowse(string $db, string $table)
Function to get the default sql query for browsing page
void
storeTheQueryAsBookmark(string $db, string $bookmarkUser, string $sqlQueryForBookmark, string $bookmarkLabel, bool $bookmarkReplace, bool $hasBookmarkAllUsers)
Function to store the query as a bookmark
string
executeQueryAndSendQueryResponse(ServerRequest $request, StatementInfo|null $statementInfo, bool $isGotoFile, string $db, string|null $table, string $sqlQueryForBookmark, string $messageToShow, string $goto, string|null $dispQuery, Message|null $dispMessage, string $sqlQuery, string $completeQuery)
Function to execute the query and send the response
string
executeQueryAndGetQueryResponse(ServerRequest $request, StatementInfo $statementInfo, bool $isGotoFile, string $db, string|null $table, string $sqlQueryForBookmark, string $messageToShow, string $goto, string|null $dispQuery, Message|null $dispMessage, string $sqlQuery, string $completeQuery)
Function to execute the query and send the response