Simple Query Example
In this query example, let's say you want to find all the rules on a device with an IP address of 192.168.20.2. Rules are the default data returned by every SIQL query unless you specifically indicate you want different data, such as counts, percentages, or policy names, by using functions.
In SIQL, you can write this query as a single filter using the simple query structure of stanza{attribute operator 'argument'}. This query does not use a function, though more sophisticated queries will.
device{managementIp='192.168.20.1'}
The stanza is device. By using the device stanza, you indicate that you want to query at the device level, and not at the level of other stanzas, such as rule or policy.
The attribute is managementIp. The word "managementIp" is the name of a field in the device stanza. By using it in the query, you indicate that you want to search for a device by its IP address.
The operator is the equals sign.
The argument is 192.168.20.1, which indicates that for "managementIp," we want to find only rules for a device with an IP address value in the database of 192.168.20.1. The single quotes ' ', enclose the expression managementIp='192.168.20.1'.
In addition to a string, an argument can also be a boolean or a number, in which case it would not need to be enclosed in single quotes.
The braces { } enclose the expression "managementIP='192.168.20.1'".