elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
20.54k stars 8.37k forks source link

ES|QL Table Visualization unable to mix data types for metrics #220490

Open BenB196 opened 1 month ago

BenB196 commented 1 month ago

Kibana version: 8.18.1

Elasticsearch version: 8.18.1

Server OS version: Container

Browser version: N/A

Browser OS version: N/A

Original install method (e.g. download page, yum, from source, etc.): Docker

Describe the bug:

When trying to create an ES|QL table visualization, in the metrics section, you can't currently mix data types (keyword & number), but its technically possible, because the ES|QL editor will pre-populate the table with a mix type.

Steps to reproduce:

  1. Create a dashboard
  2. Create an ES|QL Table visualization
  3. Use a query that adds at least 1 number column and 3 keyword columns
  4. Observe that the ES|QL metrics section gets populated with both the number column and at least 1 keyword column
  5. Attempt to add an additional keyword column to the metrics section
  6. Observe that the column name is grayed out and not selectable
  7. Remove the number column from the metrics section
  8. Observe that the keyword column in step 5 can now be added

Expected behavior:

Given that the prepopulated metrics are able to mix data types and non-ES|QL tables are able to mix data types, I would expect that I should be able to add columns of various data types to ES|QL table visualizations.

Screenshots (if relevant):

Errors in browser console (if relevant):

Provide logs and/or server output (if relevant):

Any additional context:

elasticmachine commented 1 month ago

Pinging @elastic/kibana-esql (Team:ESQL)

elasticmachine commented 1 month ago

Pinging @elastic/kibana-visualizations (Team:Visualizations)

dej611 commented 3 weeks ago

Managed to reproduce it in main. I think the current behaviour is not correct and it needs to be fixed as it's a bug.