Equals node
Description
The Equals node takes two inputs. It filters the items in your query by checking if the first input is equal to the second input.
Usage
The Equals node is a condition, so it can be added to the query branch directly after the root node or a logical node.
It can be populated with these nodes:
- Count
- Length
- all the Reference nodes
- all the Value nodes
- all the Arithmetic nodes
Configuration
-
Swap - change the comparison node. If any segments hold values, they'll remain but the node types offered will be limited.
-
Delete - remove the node from the query.
-
Link negated - enable this to invert the condition imposed by the node. Items must now fail the condition to be included in the query results.
If you enable Link negated when comparing an Attribute node, the query will also fetch items where the attribute holds no value at all. If this isn't desirable, use the Not equals node instead!
Example
Fetch all defects that are awaiting inspection
In full detail:
Fetch items of the Defects interface where their Status attribute equals Awaiting Inspection To see this example built step-by-step, see Example 1 - Check attribute.
See JSON code
{
"type": "Query",
"properties": {
"attributes": ["attributes_itemsTitle", "attributes_itemsSubtitle", "attributes_defectsStatus"],
"collectionCode": "Live",
"dodiCode": "designInterfaces_defects"
},
"children": [
{
"type": "Equals",
"children": [
{
"type": "Attribute",
"properties": {
"attributeCode": "attributes_defectsStatus"
}
},
{
"type": "AlloyId",
"properties": {
"value": ["5c8bdfb58ae862230019dc1f"]
}
}
]
}
]
}