aggregation
This block is part of the query group and was last modified in core v13.0.4.
Connection Type
This block connects from a query type block. Make sure to connect this block to the appropriate left-hand side connection.
aggregation v13.0.4 Build an aggregation on the given query.
- Name required
value - Type required
aggregation - Sub. aggregation
querySuggestions:
query_aggregation - Range Filter
querySuggestions:
query_bool_range_gtquery_bool_range_gtequery_bool_range_ltequery_bool_range_lt - Meta Data
v13.0.4objectTo associate custom metadata with an aggregation
- query
query
Builds an aggregation object {"aggs": {name: type-definition}}; an empty name pin or an unwired/nil type pin outputs an empty object {}. A non-nil meta pin is added as "meta" and a sub_agg object is deep-merged into the aggregation body. A filter object adds a sibling bucket_selector aggregation named "<name>_filter" whose script joins one "params.keyName <op> <value>" condition per filter key (gt/lt/lte/gte); any other filter key falls through to a >= comparison using the gte entry's value.
A typical wiring for aggregation: value feeds the name pin; cardinality feeds the type pin; the query out pin feeds search.
Commonly used with
In production blueprints, this block is most often wired together with:
- search: this block feeds into it. searches in the given storage based on a query.
- value: feeds into this block. Simply returns the provided value.
- cardinality: feeds into this block. Counts the approximate number of distinct values for the specified field.
- terms: feeds into this block. Performs term-based grouping, allowing aggregation on specified criteria.
- count on field: feeds into this block. Counts the occurrences of values in the specified numeric, date, or value field.
Used in these guides
These documentation pages use or explain this block:
Version history
Introduced in v13.0.4.
Back to
query Return to the main group to view all sub-groups Back to query Return to the group to view all blocks within this group 