metabase / metabase

The simplest, fastest way to get business intelligence and analytics to everyone in your company :yum:
https://metabase.com
Other
38.05k stars 5.05k forks source link

BE - Metric as data source #38679

Open ranquild opened 7 months ago

ranquild commented 7 months ago

Query execution changes described here https://www.notion.so/metabase/Metric-v2-query-changes-25385f9fed3e4f22aa7f919786c260a7

camsaul commented 7 months ago

I think the only thing we need to do here is have the aggregation and filter(s) (if any) from the Metric(s) get spliced into the "consumer query". This includes both :source-card, if that Card is a Metric, and joins, if their :source-card is a Metric. See https://metaboat.slack.com/archives/C051AG38B2S/p1707851632858039 for more discussion

camsaul commented 7 months ago

We might also need to be generating count(metric_1.*) instead of count(*) -- see https://metaboat.slack.com/archives/C051AG38B2S/p1707854775072789?thread_ts=1707851632.858039&cid=C051AG38B2S -- probably need to extend the QP to support that