opensearch-project / OpenSearch-Dashboards

📊 Open source visualization dashboards for OpenSearch.
https://opensearch.org/docs/latest/dashboards/index/
Apache License 2.0
1.69k stars 893 forks source link

[BUG] Discover can't sort directly on some half_float columns #4788

Open ananzh opened 1 year ago

ananzh commented 1 year ago

Describe the bug Seems some mapping field are not able to be sorted even sortable property is true. I have added detailed reproduce steps below.

To Reproduce Steps to reproduce the behavior:

  1. Go to Discover and use sample ecommerse data using playgroud.

  2. Add field customer_gender and taxless_total_price.

  3. Sort by 'customer_gender' and make sure we don't sort on time (need to click twice on time)

    Screenshot 2023-08-21 at 09 18 08
  4. Sort by taxless_total_price. You could see taxless_total_price is sortable for Female and Male.

    Screenshot 2023-08-21 at 09 19 13
  5. Remove customer_gender column to only sort on taxless_total_price. See errors

    Screenshot 2023-08-21 at 09 19 22
Screenshot 2023-08-21 at 09 19 28

Expected behavior No error or more guidable error message.

OpenSearch Version any

Dashboards Version any

Plugins

Please list all plugins currently enabled.

Screenshots

If applicable, add screenshots to help explain your problem.

Host/Environment (please complete the following information):

Additional context

Add any other context about the problem here.

SamriddhiS2 commented 1 year ago

I'd be interested in taking this one!