Skip to content

Commit 87464c0

Browse files
committed
1.35
1 parent 8bb4c36 commit 87464c0

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlNodeToCallOperationTest.java

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -153,10 +153,14 @@ void testCallStatement() {
153153

154154
// should throw exception when the expression argument can't be reduced
155155
// to literal
156-
// assertThatThrownBy(() -> parse("call `system`.row_result(cast((1.2 + 2.4) as decimal))"))
157-
// .hasMessageContaining(
158-
// "The argument at position 0 CAST(CAST(1.2 + 2.4 AS DECIMAL) AS DECIMAL(10, 2))
159-
// for calling procedure can't be converted to literal.");
156+
assertThatThrownBy(
157+
() ->
158+
parse(
159+
"call `system`.row_result(cast((1.2 + nullif(3, 2.4)) as decimal))"))
160+
.hasMessageContaining(
161+
"The argument at position 0 "
162+
+ "CAST(CAST(1.2 + CASE WHEN 3 = 2.4 THEN NULL ELSE 3 END AS DECIMAL) AS DECIMAL(10, 2)) "
163+
+ "for calling procedure can't be converted to literal.");
160164
}
161165

162166
private void verifyCallOperation(String sql, String expectSummary) {

0 commit comments

Comments
 (0)