I have a dashboard in which the first set of visualizations comprises a row of "Number" style visualizations/tiles. These numbers represent items in different categories, and the underlying SQL that creates them uses
WHERE logic to tease out the categories. For example:
WHERE category = 'x'
^ This would refer to a Number-tile in the dashboard called "Count of Category X".
I'd like to be able to set up click-through behavior, such that clicking on the number opens a new, saved question, called
ITEMS, which has a filter for categories. I'd like it to open this saved question and pass through the value
x to the filter.
It seems like this is not possible, since
x itself is not a filter on the original Number tile. Is there a workaround? I've also tried restructuring the query for the Number tile, like so:
SUM(CASE WHEN category = 'x' THEN 1 ELSE 0 END) AS "Count of Category X"
Any solutions? Thanks.
If you want to send parameters to a SQL question, then you'll need to create variables:
Hi @flamber, yes, this is clear to me! But maybe there's some mixup.
The visual in the dashboard, called
Count of Category X, doesn't have any variables in it. Let's call this "click-through visual".
When a user clicks on this visual, I'd like it to take them to the table called
Items, which has a filter field called
Category. Let's call this "results table". I would like the value passed to the
Category field in the results table to be equal to
Is this possible? Was my question clear?
@skye Clicking on the question title will take you to that question. Number/Trend visualization shows the title below the value, which is different from all other visualizations, so maybe that's the confusing part.
https://github.com/metabase/metabase/issues/25594 - upvote by clicking on the first post
You can make a Click Behavior on the value, which is parsed onto the destination question (as long as the destination question is either GUI or SQL with variables).
If I'm still misunderstanding what you are trying to do, then it's easier if you:
- Include "Diagnostic Info" from Admin > Troubleshooting
- Use the Sample Database to create an example (provide the steps) and use screenshots.