Query builder for SELECT statements.

Hierarchy

Expanded class hierarchy of SelectQuery

Related topics

File

core/includes/database/select.inc, line 1050
Contains classes and interfaces for Select queries.

Members

Contains filters are case sensitive
Namesort descending Modifiers Type Description
Query::$comments protected property An array of comments that can be prepended to a query.
Query::$connection protected property The connection object on which to run this query.
Query::$connectionKey protected property The key of the connection object.
Query::$connectionTarget protected property The target of the connection object.
Query::$nextPlaceholder protected property The placeholder counter.
Query::$queryOptions protected property The query options to pass on to the connection object.
Query::$uniqueIdentifier protected property A unique identifier for this query object, as generated by uniqid().
Query::comment public function Adds a comment to the query.
Query::getComments public function Returns a reference to the comments array for the query.
Query::nextPlaceholder public function Gets the next placeholder value for this query object. Overrides QueryPlaceholderInterface::nextPlaceholder
Query::uniqueIdentifier public function Returns a unique identifier for this object. Overrides QueryPlaceholderInterface::uniqueIdentifier
Query::__sleep public function Implements the magic __sleep function to disconnect from the database.
Query::__wakeup public function Implements the magic __wakeup function to reconnect to the database.
SelectQuery::$alterMetaData protected property A list of arbitrary metadata that may be attached to the query.
SelectQuery::$alterTags protected property A list of tags by which this query may be altered.
SelectQuery::$distinct protected property Whether or not this query should be DISTINCT
SelectQuery::$expressions protected property The expressions to SELECT as virtual fields.
SelectQuery::$fields protected property The fields to SELECT.
SelectQuery::$forUpdate protected property The FOR UPDATE status
SelectQuery::$group protected property The fields by which to group.
SelectQuery::$having protected property The conditional object for the HAVING clause.
SelectQuery::$order protected property The fields by which to order this query.
SelectQuery::$prepared protected property Indicates if preExecute() has already been called.
SelectQuery::$range protected property The range limiters for this query.
SelectQuery::$tables protected property The tables against which to JOIN.
SelectQuery::$union protected property An array whose elements specify a query to UNION, and the UNION type. The 'type' key may be '', 'ALL', or 'DISTINCT' to represent a 'UNION', 'UNION ALL', or 'UNION DISTINCT'…
SelectQuery::$where protected property The conditional object for the WHERE clause.
SelectQuery::addExpression public function Adds an expression to the list of "fields" to be selected. Overrides SelectQueryInterface::addExpression
SelectQuery::addField public function Adds a field to the list to be SELECTed. Overrides SelectQueryInterface::addField
SelectQuery::addJoin public function Join against another table in the database. Overrides SelectQueryInterface::addJoin
SelectQuery::addMetaData public function Overrides QueryAlterableInterface::addMetaData
SelectQuery::addTag public function Overrides QueryAlterableInterface::addTag
SelectQuery::arguments public function Gets a complete list of all values to insert into the prepared statement. Overrides QueryConditionInterface::arguments
SelectQuery::compile public function Compiles the saved conditions for later retrieval. Overrides QueryConditionInterface::compile
SelectQuery::compiled public function Check whether a condition has been previously compiled. Overrides QueryConditionInterface::compiled
SelectQuery::condition public function Overrides QueryConditionInterface::condition
SelectQuery::conditions public function Gets a complete list of all conditions in this conditional clause. Overrides QueryConditionInterface::conditions
SelectQuery::countQuery public function Overrides SelectQueryInterface::countQuery
SelectQuery::distinct public function Sets this query to be DISTINCT. Overrides SelectQueryInterface::distinct
SelectQuery::execute public function Runs the query against the database. Overrides Query::execute
SelectQuery::exists public function Overrides QueryConditionInterface::exists
SelectQuery::extend public function Overrides QueryExtendableInterface::extend
SelectQuery::fields public function Overrides SelectQueryInterface::fields
SelectQuery::forUpdate public function Overrides SelectQueryInterface::forUpdate
SelectQuery::getArguments public function Compiles and returns an array of the arguments for this prepared statement. Overrides SelectQueryInterface::getArguments
SelectQuery::getExpressions public function Returns a reference to the expressions array for this query. Overrides SelectQueryInterface::getExpressions
SelectQuery::getFields public function Returns a reference to the fields array for this query. Overrides SelectQueryInterface::getFields
SelectQuery::getGroupBy public function Returns a reference to the group-by array for this query. Overrides SelectQueryInterface::getGroupBy
SelectQuery::getMetaData public function Overrides QueryAlterableInterface::getMetaData
SelectQuery::getOrderBy public function Returns a reference to the order by array for this query. Overrides SelectQueryInterface::getOrderBy
SelectQuery::getTables public function Returns a reference to the tables array for this query. Overrides SelectQueryInterface::getTables
SelectQuery::getUnion public function Returns a reference to the union queries for this query. This include queries for UNION, UNION ALL, and UNION DISTINCT. Overrides SelectQueryInterface::getUnion
SelectQuery::groupBy public function Overrides SelectQueryInterface::groupBy
SelectQuery::hasAllTags public function Determines if a given query has all specified tags. Overrides QueryAlterableInterface::hasAllTags
SelectQuery::hasAnyTag public function Determines if a given query has any specified tag. Overrides QueryAlterableInterface::hasAnyTag
SelectQuery::hasTag public function Determines if a given query has a given tag. Overrides QueryAlterableInterface::hasTag
SelectQuery::having public function Implements QueryConditionInterface::having().
SelectQuery::havingArguments public function Returns all the arguments used within a HAVING clause.
SelectQuery::havingCompile public function
SelectQuery::havingCondition public function Overrides SelectQueryInterface::havingCondition
SelectQuery::havingConditions public function Returns all the conditions used within a HAVING clause.
SelectQuery::havingExists public function
SelectQuery::havingIsNotNull public function
SelectQuery::havingIsNull public function
SelectQuery::havingNotExists public function
SelectQuery::innerJoin public function Inner Join against another table in the database. Overrides SelectQueryInterface::innerJoin
SelectQuery::isNotNull public function Overrides QueryConditionInterface::isNotNull
SelectQuery::isNull public function Overrides QueryConditionInterface::isNull
SelectQuery::isPrepared public function Indicates if preExecute() has already been called on that object. Overrides SelectQueryInterface::isPrepared
SelectQuery::join public function Default Join against another table in the database. Overrides SelectQueryInterface::join
SelectQuery::leftJoin public function Left Outer Join against another table in the database. Overrides SelectQueryInterface::leftJoin
SelectQuery::notExists public function Overrides QueryConditionInterface::notExists
SelectQuery::orderBy public function Overrides SelectQueryInterface::orderBy
SelectQuery::orderRandom public function Overrides SelectQueryInterface::orderRandom
SelectQuery::preExecute public function Generic preparation and validation for a SELECT query. Overrides SelectQueryInterface::preExecute
SelectQuery::range public function Overrides SelectQueryInterface::range
SelectQuery::rightJoin public function Right Outer Join against another table in the database. Overrides SelectQueryInterface::rightJoin
SelectQuery::union public function Overrides SelectQueryInterface::union
SelectQuery::where public function Overrides QueryConditionInterface::where
SelectQuery::__clone public function Implements the magic __clone function. Overrides Query::__clone
SelectQuery::__construct public function Constructs a Query object. Overrides Query::__construct
SelectQuery::__toString public function Implements PHP magic __toString method to convert the query to a string. Overrides Query::__toString