Skip to content
This repository was archived by the owner on Dec 20, 2024. It is now read-only.

Clause Connectors AND, OR, and Parentheses (Spider)

JoeWinter edited this page Sep 19, 2014 · 1 revision

[Table of Contents](https://github.com/dell-oss/Doradus/wiki/Spider Databases: Table-of-Contents) | [Previous](https://github.com/dell-oss/Doradus/wiki/Clause Negation NOT (Spider)) | Next
Doradus Query Language: Clause Connectors AND, OR, and Parentheses


Clauses are *implicitly* connected with "and" semantics by separating them with at least one whitespace character. For example:

LastName:Wright Department:Sales

This query consists of two clauses and is identical to the following query expression:

LastName:Wright AND Department:Sales

Clauses can be explicitly connected with the uppercase keywords AND and OR. When a DQL query has a mixture of AND and OR clauses, the AND clauses have higher evaluation precedence. For example:

Origin=3 AND Platform=2 OR SendDate='2011-10-01' AND Size=1000

This is evaluated as if the following parentheses were used:

(Origin=3 AND Platform=2) OR (SendDate='2011-10-01' AND Size=1000)

Parentheses can be used to change the evaluation order. For example:

Origin=3 AND (Platform=2 OR SendDate='2011-10-01') AND Size=1000

Clone this wiki locally