Skip to content

Apache DataFusion SQL Query Engine

Add regression coverage for DATE interval overflow (#22519)

Puneet Dixit8a9653c64983
diff --git a/datafusion/sqllogictest/test_files/datetime/arith_date_interval.slt b/datafusion/sqllogictest/test_files/datetime/arith_date_interval.slt
index 01e1939996..12fcc2bfd3 100644
--- a/datafusion/sqllogictest/test_files/datetime/arith_date_interval.slt
+++ b/datafusion/sqllogictest/test_files/datetime/arith_date_interval.slt
@@ -47,3 +47,6 @@ SELECT arrow_cast('2020-01-01', 'Date64') + INTERVAL '999999' YEAR
query error Arrow error: Compute error: Date arithmetic overflow
SELECT arrow_cast('2020-01-01', 'Date64') - INTERVAL '999999' YEAR
+
+query error Arrow error: Compute error: Date arithmetic overflow
+SELECT DATE '2262-04-10' + INTERVAL '999999999' DAY