top
Table of Contents
This command is experimental |
Definition
top
searches the most common values for selected table column and counts the frequency of occurrence in that selected table column.
Syntax
| top [(limit=)<int>] [countfield=<string>] [percentfield=<string>] [showcount=<boolean>] [showperc=<boolean>] [useother=<boolean>] [otherstr=<string>] <column-name> [BY <column-name>, ...]
Examples
When top
is used, the query returns the table column used in the query, count
column and percent
column.
Currently, Due to this:
|
index=example earliest=-5y
| top _raw

limit
Use limit
argument to change how many results top
returns. You can use the abbreviated version or the complete one.
%dpl
index=example earliest=-5y
| top 5 _raw
%dpl
index=example earliest=-5y
| top limit=5 _raw
Currently, |
If the limit
argument isn’t used, top
returns 10 results by default.