public function Solr_Base_Query::add_subquery in Apache Solr Search 6
Same name and namespace in other branches
- 5.2 Solr_Base_Query.php \Solr_Base_Query::add_subquery()
- 5 Solr_Base_Query.php \Solr_Base_Query::add_subquery()
- 6.2 Solr_Base_Query.php \Solr_Base_Query::add_subquery()
Add a subquery to the query.
Parameters
Drupal_Solr_Query_Interface $query: The query to add to the orginal query - may have keywords or filters.
string $fq_operator: The operator to use within the filter part of the subquery
string $q_operator: The operator to use in joining the subquery to the main keywords. Note - this is unlikely to work with the Dismax handler when the main query is only keywords.
Overrides Drupal_Solr_Query_Interface::add_subquery
File
- ./
Solr_Base_Query.php, line 255
Class
Code
public function add_subquery(Drupal_Solr_Query_Interface $query, $fq_operator = 'OR', $q_operator = 'AND') {
$this->subqueries[$query->id] = array(
'#query' => $query,
'#fq_operator' => $fq_operator,
'#q_operator' => $q_operator,
);
}