Skip to content

Commit 12f71bf

Browse files
committed
fix(cubesql): Yield a sensible error on MEASURE function push down
1 parent 05ea7e2 commit 12f71bf

File tree

1 file changed

+3
-1
lines changed
  • rust/cubesql/cubesql/src/compile/engine/udf

1 file changed

+3
-1
lines changed

rust/cubesql/cubesql/src/compile/engine/udf/common.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2264,7 +2264,9 @@ pub fn create_measure_udaf() -> AggregateUDF {
22642264
DataType::Float64,
22652265
Arc::new(DataType::Float64),
22662266
Volatility::Immutable,
2267-
Arc::new(|| todo!("Not implemented")),
2267+
Arc::new(|| {
2268+
Err(DataFusionError::NotImplemented("MEASURE function was used in context where it's not supported. Try replacing MEASURE with the measure type-matching function (SUM/AVG/etc).".to_string()))
2269+
}),
22682270
Arc::new(vec![DataType::Float64]),
22692271
)
22702272
}

0 commit comments

Comments
 (0)