This document describes the Advanced Query Language syntax.
General syntax
The search query string has the following general form:
$<attribute> <predicate> | <coperator> "<value>" [[<loperator> [(]<attribute> <predicate> | <coperator> <value>[)]] ... ]
Example query syntax:
Find all connected resources with the string cle
in the name.
Example query result:
Attributes
Precede attribute names with a $
symbol. As you type, the dialog displays a list of matching attributes. Use the mouse or down-arrow key to highlight and select the attribute you want.
Attribute values
Attributes and attribute values form a key:value pair. Enclose non-integer attribute values in quotes: $name = "Activemq"
. You do not need to quote integer value types.
Logical operators
Operator | Description |
---|---|
AND | Compares two predicate statements and returns true both predicates evaluate to true . |
OR | Performs an inclusive OR operation on two predicate statements and returns true if either or both predicates evaluate to true . |
Precedence
Use parentheses to control the order of evaluation of predicate clauses. Predicates clauses within parentheses are evaluated before non-parenthetical clauses. The most deeply nested parenthetical clause is evaluated first.
Comparison operators
Operator | Description |
---|---|
= | Equal to. Evaluates to true if operands are equal. |
!= | Not equal to. Evaluates to true if operands are unequal. |
<= | Less than or equal to. Evaluates to true if the left operand is less than or equal to the right operand. This operator can only be used with numeric operand data types, including date and time. |
>= | Greater than or equal to. Evaluates to true if the left operand is greater than or equal to the right operand. This operator can only be used with numeric operand data types, including date and time. |
< | Less than. Evaluates to true if the left operand is less than the right operand. This operator can only be used with numeric operand data types, including date and time. |
> | Greater than. Evaluates to true if the left operand is greater than the right operand. This operator can only be used with numeric operand data types, including date and time. |
Predicates
Predicate | Description |
---|---|
CONTAINS | The predicate clause evaluates to true if the string value exactly matches the resource value substring for the specified attribute. |
NOT CONTAINS | The predicate clause evaluates to true if the string value does not occur in the resource value for the specified attribute. |
IN | The predicate clause evaluates to true if the value is found in a list of values. |
IS | The predicate clause evaluates to true if the value exactly matches the resource value for the specified attribute. |
IS NULL | The predicate clause evaluates to true if the resource value is undefined or empty for the specified attribute. |
IS NOT NULL | The predicate clause evaluates to true if the resource value is set for the specified attribute. |