...
The general syntax of a complex search is as follows:
Code Block |
---|
search query | [function | [group] | [view]] ([function | [group] | [view]])... |
where,
search query – a simple search
funtionfunction – an operation that is applied on the results of the search preceding the pipe. Available functions: count, min, max, avg, sum, time, start time, end time, country, country code, city, region, execute
...
view – specifies how to display the results. Available View operations: first, last, order by, display, where, display only, geoip, asc, desc, display first 10
Grouping can only be according to a single group type. However, the group type can have a single or multiple variables.
A function must precede grouping, although it does not necessarily have to immediately precede it – view can come between the function and group command.
There can be multiple View types.
The Complex Search Syntax is iterative.
In the following example, there is one function (count), one grouping (group by) by two variables (event, user), and three views (order by ... desc, first, display as):
Code Block |
---|
in app.windows event logs | count | group by event, user | order by count desc | first 10 | display count as Our Example |
This chapter provides you with a reference to all the search commands available for your use in a complex search, including their syntax, description, and examples of use. You can also build complex search queries using a combination of these search commands. Complex search queries that are executed run in the XpoSearch console, can be visualized as gadgets widgets in XpoLog Dashboards.
Use case examples of such commands are provided in Complex Search Use Case Examples.