Skip to content

Commit a312f54

Browse files
committed
Update the metric.expr to be populated correctly according to DSI rules
1 parent 34c7343 commit a312f54

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

core/dbt/parser/schema_yaml_readers.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -643,7 +643,9 @@ def _create_metric(
643643
name=measure.name,
644644
label=measure.label or measure.name,
645645
type="simple",
646-
type_params=UnparsedMetricTypeParams(measure=measure.name, expr=measure.name),
646+
type_params=UnparsedMetricTypeParams(
647+
measure=measure.name, expr=measure.expr or measure.name
648+
),
647649
description=measure.description or f"Metric created from measure {measure.name}",
648650
config=config,
649651
)

0 commit comments

Comments
 (0)