Skip to content
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

Drilldown from the chart and drilldown from the results table give different results #10004

Open
magnew opened this issue May 7, 2024 · 0 comments
Labels
🐛 bug Something isn't working as expected. This can be an error or an unexpected user experience

Comments

@magnew
Copy link
Contributor

magnew commented May 7, 2024

Description

In an explore with a date field, drilling down from the chart and drilling down from the results table give different results.

The problem here is that the chart drilldown always returns the raw field, which has timezone information and the table drilldown fills in the timezone-less date. When the date filter tries to parse these using the existing logic, it gets different results.

The fix is probably to treat both values as utc explicitly and then drop the timezone. These will give the same result:

moment.utc('2018-02-02').format('YYYY-MM-DD');
moment.utc('2018-02-02T00:00:00Z').format('YYYY-MM-DD');

Steps to Reproduce the Bug or Issue

  1. In a US timezone, go to a chart with dates (How many orders we have over time?)
  2. Drilldown on february 2 from the chart
  3. You will get a filter for feb 1
  4. Try drilling down from the table
  5. You get the right date

version

No response

Cloud or self-hosting

None

@magnew magnew added the 🐛 bug Something isn't working as expected. This can be an error or an unexpected user experience label May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Something isn't working as expected. This can be an error or an unexpected user experience
Projects
None yet
Development

No branches or pull requests

1 participant