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

Custom filter widget value dropped when Exploring Results of Native SQL question #19584

Closed
rarup1 opened this issue Jan 7, 2022 · 1 comment
Labels

Comments

@rarup1
Copy link

rarup1 commented Jan 7, 2022

Describe the bug
The Explore Results feature doesn't use the Custom Filter Widget value when Exploring Results of a native script using variables. It always uses the default value set in the question which confuses end user and seems wrong.

Logs
N/A

To Reproduce
Steps to reproduce the behavior:

  1. Go to "Ask Question" and start a "Native Query"
  2. Pick a database
  3. Enter SELECT {{custom_or_default_date}} in native SQL box
  4. Configure variables:
    Set Variable type = Date
    Set Required = Yes
    Set default widget value = January 6, 2022
    Save
  5. If you explore the results now you would expect it to show 2022-01-06 00:00:00
  6. If you update the Custom or Default date widget - January 14, 2022 and explore results:
    the URL updates to: https://metabase.eng.lendinvestinternal.com/question?custom_or_default_date=2022-01-14#eyJkYXRhc2V...
    but the results still return 2022-01-06 00:00:00

Expected behavior
It should return 2022-01-14 00:00:00 as the URL parameter/Custom filter should always over ride the initial default widget value.

Screenshots
If applicable, add screenshots to help explain your problem.

Information about your Metabase Installation:

You can get this information by going to Admin -> Troubleshooting.

  • Your browser and the version: Chrome
  • Your operating system: Mac Monterwy
  • Your databases: MySQL
  • Metabase version: Metabase 0.41.5
  • Metabase hosting environment: (K8s)
  • Metabase internal database: Postgres

Severity
How severe an issue is this bug to you? Is this annoying, blocking some users, blocking an upgrade or blocking your usage of Metabase entirely?

Annoying
It is annoying as the new Explore Results feature is ace but this makes it less useful and risky to leave in the hands of the less attentive users who explore and export results from Native SQL stored questions

Additional context
Add any other context about the problem here.

@rarup1 rarup1 added .Needs Triage Type:Bug Product defects labels Jan 7, 2022
@flamber
Copy link
Contributor

flamber commented Jan 25, 2022

Duplicate of #6449, since it's currently not support to pass-thru variables to nested queries

@flamber flamber closed this as completed Jan 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants