-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Lens] Allow "count of field" by supporting the value count aggregation #74910
Comments
Pinging @elastic/kibana-app (Team:KibanaApp) |
I've opened a related issue for the Elasticsearch team about array fields: elastic/elasticsearch#64077 |
This seems especially relevant for formulas, thanks @ghudgins for raising that connection. Part of the question is whether at the formula level we would want |
Not sure how far we should reach into SQL territory with this. If we go with |
I think
Another one to 🤔 is |
I think the danger here is to make both the implementation and the tool itself more complex in order to make it easier for people to pick up formula, which will in the long term do more harm than good. Let's say we would implement
It's not the same - This is precisely the thing I'm worried about - all of these things have slightly different semantics and if we try to provide a familiar syntax targeting SQL users, we will break these subtle cases while also making the feature more complex. IMHO it's not worth it and a consistent translation of quick function to formula is more valuable than trying to look like SQL in some special cases. |
just closing the loop - I retract the tangent about count following a discussion. We agreed it's a slippery slope to support some SQL syntax and not others in custom formula. Thanks for the clarification We can continue the discussion about the value count aggregation in Lens. Appreciate the conversation! |
discussed in meeting - |
The value count aggregation lets users count the total number of indexed values for a field, and is mostly useful when dealing with arrays. This metric is supported in TSVB, but not Visualize.
For example, when using
kibana_sample_data_ecommerce
, you can use the value count aggregation to compare the number of products to the number of orders. Each order contains one or more products, so the value count is higher than the order count:Proposal:
Because the name "value count" is potentially confusing, I'm proposing that we combine Count and Value count into one aggregation that can support any field.
Dependencies:
#67403
The text was updated successfully, but these errors were encountered: