Aggregating data is a useful technique in understanding more about our data and uncovering patterns. This video shows how to run basic aggregations and the difference between buckets and metrics inside of Elasticsearch.
- [Narrator] A common task on the analytics side…that we may want to preform here…is how to create aggregations using Elasticsearch…and the search API.…So first, let's just start by taking a look…and finding out how many accounts we have…for every state in our bank account data.…So we'll say get bank account,…and then we'll do a search like usual.…And here we're going to start by doing a size of zero,…and this tells us that I don't actually want the results…from this query, I just want my aggregation back.…
Then I'm going to enter an aggs clause,…and the aggs is where we specify what types…of aggregations we want.…First, we need to name our aggregation,…so I'm going to call this states,…then for the agg type it's going to be terms,…and the field is going to be state.keyword.…And I'll go ahead and remove the size here from there.…So when I run this, you can see that I actually have…1000 hits, remember I didn't really filter this query…at all, but I didn't get any results back…other than my aggregations.…
Then I have my state value, so this is the name of my…
In this course, join Ben Sullins as he dives into the inner workings of Elasticsearch combined with Kibana. Ben provides an overview of the architecture, and then goes over the different deployment methods, and how to best structure your data. From there, he demonstrates how to query data, and how to work with Kibana to present your insights.
- Reviewing key Elasticsearch concepts
- Running Elasticsearch in the cloud and locally
- Bulk loading data
- Setting up mappings of data types
- Querying data
- Running basic aggregations
- Creating visualizations and dashboards in Kibana