Query Parameters for Dynamic Dimensions, Measures, and more

Update: See upcoming feature announcement of Dynamic Models.

Problems and Use-cases

Dynamically modifying the query result returned from data exploration according to dashboard input.

Use-cases

Proposed Solution: Query Parameter

Allow Admins/Analysts to define parameters that can inject a value to SQL/AML and dynamically change the output of the queries.

  1. Define a Query Parameter in a Data Model (or an AML project - TBD) with a set of allowed values
  2. Inject the Query Parameter to AML objects such as Dimension, Measure, Business Calculation, etc.
  3. Create a Query Parameter Filter in dashboards or visualizations to allow data consumers to change the query results according to the selected filter value

This feature is under the discovery phase and highly prioritized. We are looking for more feedback and use-cases from the community, please don’t hesitate to share them below

Fantastic to hear this is highly prioritised. Would also be good to be able to set parameters dynamically via user attributes.

3 Likes

Oh yeah, thanks for the suggestion, almost forgot about the user attributes, just added to the potential use-case :ok_hand:

Hi,

Would this be also appliccable for switching between datasource schema’s, based on the user attribute? See example AML below with the schema parameter

Model model_name {
  type: 'table'
  label: "Model Label"
  data_source_name: 'data_source_name'
  
  table_name: '"{{@schemaparam}}"."table_name"'
}

Yeah, it should be, can call it dynamic schema

@anthonytd,

Is this feature available to be activated on our account or not yet?

Hi Abdel, not yet. As mentioned in the original post, this feature is still under research & development.

Can I check in regards to this feature, will this allow URL query params to be passed to a dashboard/report so that you can created dynamic links to a dashboard and have it pre-filtered?

Hi @DataGeekDude,
This feature only allows admins/analysts to inject a value to SQL/AML and dynamically change the output of the queries. So I’m afraid that it’s not what you’re looking for.
Btw, I found that you’ve created another topic for your request here: URL Filter Parameters to filter a dashboard dynamically right away. Did Khai’s answer help solve your case?

Yes Khai’s answer did, I guess I was wondering if this was partly the fstate parameters that he mentioned in the post or if that is still to be implemented?

Hi @DataGeekDude this feature won’t cover the fstate param that Khai mentioned in your post.
At the moment, both features are still under research; however, they are highly prioritized in our roadmap. We’ll let you know when we start implementing them :blush:

Ah ok, thanks for letting me know!

1 Like

Is it possible to get an ETA on this feature?
I have a bunch of use cases that depend on this and I would like to know if its worth investing time into alternative solutions.

We’ve started the Research phase for this functionality Gabriel. But just to make sure, could you share your specific use cases so that we know if we’re building will fit with what you have in mind?

Most pressingly for me would be the ability to “segment” users for the Retention Heatmap / Cohort visualization, which right now requires me to pre-aggregate on various user attributes and is neither sustainable nor elegant.
Passing through a dashboard filter to a query model’s WHERE clause would solve this issue.

The same could be solved if it were possible to build the Retention Heatmap / Cohort visualization with more dynamic inputs (SUM(x) as cohort size etc.) - but that’s a different topic.

2 Likes

Well noted Gabriel. That’s exactly the use case that this functionality would solve. As shared we’re in the research and design phase for this functionality at the moment. I hope to share some specification with you when we get to something concrete.

I have another use case for you @huy:
We want to make a dashboard for financial “What If” analysis.

Say we have a dashboard with a pivot table with our actual P&L results and our forecasted results for the next years.

I would then like to use parameters to control for an x% increase or decrease to some metric and how that affects our results.

If I had a parameter, where I could set it to a 5% drop I could then inject that into my measure and all other measures, that depend on it.

This is something that I am currently trying to solve as we have hundreds different excel spreadsheets with different variations today, and it is very hard to manage.

1 Like

Thanks for the additional use cases Martin. We’re starting the implementation for this feature. We will share more updates later this month on this.

2 Likes

Hi all, we’re making an early announcement of the feature here to make sure it aligns with our users’ expectations. Please see the announcement here: