Event and Field Selection Query Functions

LogScale's selection functions select, rename, or remove fields. They can also select, sort, or drop events, for example to keep the first, last, or top events, or a random sample.

Table: Event and Field Selection Query Functions

FunctionDefault ArgumentAvailabilityDescription
array:drop(array)array  Takes the name of a flat array and drops all fields of this array.
array:rename(array, asArray)array  Takes the name of an array and renames all fields of this array.
drop(fields, [mode])fields  Removes specified fields from each event.
dropEvent()   Drops completely an event in parser pipeline to stop it from being ingested.
head([limit])limit  Returns the oldest events from an event stream.
rename([as], field)field  Renames one or more given fields.
sample([field], [percentage])percentage  Samples the event stream.
select(fields)fields  Used to specify a set of fields to select from each event.
selectFromMax(field, include)field  Selects event with the largest value for the specified field.
selectFromMin(field, include)field  Selects event with the smallest value for the specified field.
selectLast(fields)fields  Specify fields to select from events, keeping value of most recent event for each field.
sort([field], [limit], [order], [reverse], [type])field  Sorts events by their fields.
tail([limit])limit  Returns the newest events from an event stream.