jpedroantunes commented on a change in pull request #9906:
URL: https://github.com/apache/arrow/pull/9906#discussion_r609700272



##########
File path: cpp/src/gandiva/gdv_function_stubs_test.cc
##########
@@ -160,4 +160,13 @@ TEST(TestGdvFnStubs, TestCastFloat8) {
   ctx.Reset();
 }
 
+TEST(TestGdvFnStubs, TestIsDate) {
+  EXPECT_EQ(gdv_fn_is_date_utf8("2020-01-01", 10), true);
+  EXPECT_EQ(gdv_fn_is_date_utf8("1524-12-31", 10), true);
+  EXPECT_EQ(gdv_fn_is_date_utf8("0001-01-01", 10), true);
+  EXPECT_EQ(gdv_fn_is_date_utf8("2020-01-01 12:00:00", 19), false);

Review comment:
       Yes, you are right, the ISDATE function should return true since it is 
castable to a data YYYY-MM-DD format.
   Corrected the behavior of the function




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to