-
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] Support drilldowns in charts with only one dimension (when it is a formula) #151726
Comments
Pinging @elastic/kibana-visualizations @elastic/kibana-visualizations-external (Team:Visualizations) |
@drewdaemon they are supported Am I missing something? |
The problem is not general but only if formulas are applied (it works fine with quick functions) |
I checked this issue and it happens for the following reason:
The look like that
```
[
{
"id": "c0df5a54-b17a-475c-8dde-8da22af9c696X0",
"name": "Part of min(AvgTicketPrice)",
"meta": {
"type": "number",
"field": "AvgTicketPrice",
"index": "kibana_sample_data_flights",
"params": {
"id": "number",
"params": {
"pattern": "$0,0.[00]"
}
},
"source": "esaggs",
"sourceParams": {
"hasPrecisionError": false,
"indexPatternId": "d3d7af60-4c81-11e8-b3d7-01146121b73d",
"id": "0",
"enabled": true,
"type": "min",
"params": {
"field": "AvgTicketPrice"
},
"schema": "metric"
}
}
},
{
"id": "c0df5a54-b17a-475c-8dde-8da22af9c696",
"name": "min(AvgTicketPrice)",
"meta": {
"type": "number",
"params": {
"id": "number"
}
}
}
]
```
When we are checking if a filter is compatible to create a drilldown we are using the visible column (this makes sense to me) and the reason it returns incompatible is simply because it fails here https://github.com/elastic/kibana/blob/main/src/plugins/data/public/actions/filters/create_filters_from_value_click.ts#L84 The Part of column has this information, so I wonder which is the best approach here. Why the visible column doesnt have this information? Should we pass it from the partial column to the visible one or should we create the filter from the partial column? @dej611 you know formulas better than me. Can you take a look? |
Another update on this:
The same behavior exists if I have a bar chart with a formula (and no x-axis/split dimension) I am changing to an enhancement. |
hi @drewdaemon and @stratoula , I had some time to check this out on the 8.9 version (see recording): Skaermoptagelse.2023-05-11.kl.21.36.06.movI want to make sure I understand this 💯 , so apologies for going into too many details perhaps 😃 I have two metric visualizations both of them with exactly the same drill-downs.
The one with formula is not working with drill-down as mentioned by both of you above ⬆️ My take from the user perspective is that the drill-down should behave the same way regardless of how the calculation is done (formula or quick function). Currently, the user does not get any information why the drill-down he/she just setup on a metric with formula is not working @stratoula : Could you perhaps elaborate on this: "metrics with formula and dropdowns work fine." Do you mean metric with quick functions? WDYT ? |
|
Thanks 🙏 I was looking at this late last night. With your explanation and a read, it makes more sense. 😊
I still think it would make sense to support:
For metrics with math i.e. min(field) + max(field). :
|
|
In order to provide better transparency of priorities, issues that will not be prioritized within the next 24 months are being closed. Tracking request in Lens general improvements ice box #184459 |
If I have a chart with only one dimension (metric) which is a formula then the drilldowns are not applied.
We could possibly allow them but then there is the question on which filters should be applied:
The text was updated successfully, but these errors were encountered: