Dashboard filters on views

I have run into an issue with Dashboard filters in v0.33.2.

For some reason, Metabase shows "no available" fields when I try to assign a Dashboard filter to a Simple question based on a MySQL view.
At the same time, Dashboard filters work correctly with a Question based on the MySQL table.

Example:

  1. MySQL View-based Simple question built with Metabase builder (no custom code):

    => Cannot use its fields with a Dashboard filter:
    image
  2. MySQL Table-based Simple question built with Metabase builder (no custom code):

    => Can use its fields on with a Dashboard filter

I've checked it for Metabase 0.32.10, it and handles the same view-based Question properly:
Question:


Dashboard:
image

Hi @dtroyan
I’m not sure how, but notice the order of the Filter and Summarize sections between the working and non-working question.
Try re-doing the non-working question and first define the Filter and then Summarize.
If you can provide steps-to-reproduce for how the order was set to Summarize and then Filter, then please provide those steps, since that seems like a bug.

Hi @flamber,
Apparently, you were right:

  1. Custom Question
  2. Choose table
  3. Set up Summarize metric and Grouping field
  4. Click on the "Visualize" button
  5. Click on the "Show editor" button
    image
    => "Filter" section is gone
  6. Click on the "Filter" button
    => the "Filter" section is added at the bottom, after the "Summarize" section.
  7. Save the Question, add it to a Dashboard, and then its fields become unavailable for the Dashboard filters (as on the screenshot above)

@flamber, actually, I've noticed that setting up a Metric filter also makes it impossible to use Dashboard filters on the Question. Even if the operations order is the following:

  1. Filter by table fields
  2. Summarize
  3. Filter by metric

    It seems to me like a bug as well, please have a look.

@dtroyan
Great. Thanks for the steps-to-reproduce!
When using the Editor, it can quickly become tricky, since you can do table joins and havings.
Notice the Filter-icon right below the Data-section - that’s the filter you’re interested in.
If you use the bottom filter, then it will make a filter on the summarized data - and to that, it’s doing a sub-query, which is messing with your dashboard filters.

@maz Very similar to what I reported in the previews. Not sure if something needs to be explained differently or documentation should cover this?