@@ -38,7 +38,7 @@ using namespace ut_type;
3838TEST (VTimestampFunctionsTest, day_of_week_test) {
3939 std::string func_name = " dayofweek" ;
4040
41- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
41+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
4242
4343 DataSet data_set = {{{std::string (" 2001-02-03 12:34:56" )}, int8_t {7 }}};
4444
@@ -48,7 +48,7 @@ TEST(VTimestampFunctionsTest, day_of_week_test) {
4848TEST (VTimestampFunctionsTest, day_of_month_test) {
4949 std::string func_name = " dayofmonth" ;
5050
51- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
51+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
5252
5353 DataSet data_set = {{{std::string (" 2020-01-01 00:00:00" )}, int8_t {1 }},
5454 {{std::string (" 2020-02-29 00:00:00" )}, int8_t {29 }}};
@@ -59,7 +59,7 @@ TEST(VTimestampFunctionsTest, day_of_month_test) {
5959TEST (VTimestampFunctionsTest, day_of_year_test) {
6060 std::string func_name = " dayofyear" ;
6161
62- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
62+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
6363
6464 DataSet data_set = {{{std::string (" 2020-02-29 00:00:00" )}, int16_t {60 }}};
6565
@@ -69,7 +69,7 @@ TEST(VTimestampFunctionsTest, day_of_year_test) {
6969TEST (VTimestampFunctionsTest, week_of_year_test) {
7070 std::string func_name = " weekofyear" ;
7171
72- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
72+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
7373
7474 DataSet data_set = {{{std::string (" 2020-02-29 00:00:00" )}, int8_t {9 }}};
7575
@@ -79,7 +79,7 @@ TEST(VTimestampFunctionsTest, week_of_year_test) {
7979TEST (VTimestampFunctionsTest, year_test) {
8080 std::string func_name = " year" ;
8181
82- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
82+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
8383
8484 DataSet data_set = {{{std::string (" 2021-01-01 00:00:00" )}, int16_t {2021 }},
8585 {{std::string (" 2025-05-01 00:00:00" )}, int16_t {2025 }}};
@@ -90,7 +90,7 @@ TEST(VTimestampFunctionsTest, year_test) {
9090TEST (VTimestampFunctionsTest, quarter_test) {
9191 std::string func_name = " quarter" ;
9292
93- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
93+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
9494
9595 DataSet data_set = {{{std::string (" 2021-01-01 00:00:00" )}, int8_t {1 }},
9696 {{std::string (" 2025-10-23 00:00:00" )}, int8_t {4 }}};
@@ -101,7 +101,7 @@ TEST(VTimestampFunctionsTest, quarter_test) {
101101TEST (VTimestampFunctionsTest, month_test) {
102102 std::string func_name = " month" ;
103103
104- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
104+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
105105
106106 DataSet data_set = {{{std::string (" 2021-01-01 00:00:00" )}, int8_t {1 }},
107107 {{std::string (" 2025-05-23 00:00:00" )}, int8_t {5 }}};
@@ -112,7 +112,7 @@ TEST(VTimestampFunctionsTest, month_test) {
112112TEST (VTimestampFunctionsTest, day_test) {
113113 std::string func_name = " day" ;
114114
115- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
115+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
116116
117117 DataSet data_set = {{{std::string (" 2021-01-01 00:00:00" )}, int8_t {1 }},
118118 {{std::string (" 2025-05-23 00:00:00" )}, int8_t {23 }}};
@@ -123,7 +123,7 @@ TEST(VTimestampFunctionsTest, day_test) {
123123TEST (VTimestampFunctionsTest, hour_test) {
124124 std::string func_name = " hour" ;
125125
126- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
126+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
127127
128128 DataSet data_set = {{{std::string (" 2021-01-01 23:59:59" )}, int8_t {23 }},
129129 {{std::string (" 2021-01-13 16:56:00" )}, int8_t {16 }}};
@@ -134,7 +134,7 @@ TEST(VTimestampFunctionsTest, hour_test) {
134134TEST (VTimestampFunctionsTest, minute_test) {
135135 std::string func_name = " minute" ;
136136
137- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
137+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
138138
139139 DataSet data_set = {{{std::string (" 2021-01-01 23:59:50" )}, int8_t {59 }},
140140 {{std::string (" 2021-01-13 16:20:00" )}, int8_t {20 }}};
@@ -145,7 +145,7 @@ TEST(VTimestampFunctionsTest, minute_test) {
145145TEST (VTimestampFunctionsTest, second_test) {
146146 std::string func_name = " second" ;
147147
148- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
148+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
149149
150150 DataSet data_set = {
151151 {{std::string (" 2021-01-01 23:50:59" )}, int8_t {59 }},
@@ -234,7 +234,7 @@ TEST(VTimestampFunctionsTest, unix_timestamp_test) {
234234TEST (VTimestampFunctionsTest, timediff_test) {
235235 std::string func_name = " timediff" ;
236236
237- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME , PrimitiveType::TYPE_DATETIME };
237+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 , PrimitiveType::TYPE_DATETIMEV2 };
238238
239239 DataSet data_set = {
240240 {{std::string (" 2019-07-18 12:00:00" ), std::string (" 2019-07-18 12:00:00" )},
@@ -290,7 +290,7 @@ TEST(VTimestampFunctionsTest, convert_tz_test) {
290290TEST (VTimestampFunctionsTest, date_format_test) {
291291 std::string func_name = " date_format" ;
292292
293- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME ,
293+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 ,
294294 Consted {PrimitiveType::TYPE_VARCHAR}};
295295 {
296296 DataSet data_set = {{{std::string (" 2009-10-04 22:23:00" ), std::string (" %W %M %Y" )},
@@ -341,7 +341,7 @@ TEST(VTimestampFunctionsTest, date_format_test) {
341341TEST (VTimestampFunctionsTest, to_days_test) {
342342 std::string func_name = " to_days" ;
343343
344- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
344+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
345345
346346 DataSet data_set = {
347347 {{std::string (" 2021-01-01 00:00:00" )}, 738156 },
@@ -353,19 +353,19 @@ TEST(VTimestampFunctionsTest, to_days_test) {
353353TEST (VTimestampFunctionsTest, date_test) {
354354 std::string func_name = " date" ;
355355
356- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
356+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
357357
358358 DataSet data_set = {
359359 {{std::string (" 2021-01-01 06:00:00" )}, std::string (" 2021-01-01" )},
360360 };
361361
362- static_cast <void >(check_function<DataTypeDate , true >(func_name, input_types, data_set));
362+ static_cast <void >(check_function<DataTypeDateV2 , true >(func_name, input_types, data_set));
363363}
364364
365365TEST (VTimestampFunctionsTest, week_test) {
366366 std::string func_name = " week" ;
367367
368- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
368+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
369369
370370 DataSet data_set = {{{std::string (" 1989-03-21 06:00:00" )}, int8_t {12 }},
371371 {{std::string (" 9999-12-12 00:00:00" )}, int8_t {50 }}};
@@ -376,7 +376,7 @@ TEST(VTimestampFunctionsTest, week_test) {
376376TEST (VTimestampFunctionsTest, yearweek_test) {
377377 std::string func_name = " yearweek" ;
378378
379- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
379+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
380380
381381 DataSet data_set = {{{std::string (" 1989-03-21 06:00:00" )}, 198912 },
382382 {{std::string (" 9999-12-12 00:00:00" )}, 999950 }};
@@ -402,7 +402,7 @@ TEST(VTimestampFunctionsTest, weekday_test) {
402402 std::string func_name = " weekday" ;
403403
404404 {
405- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
405+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
406406
407407 DataSet data_set = {
408408 {{std::string (" 2001-02-03 12:34:56" )}, int8_t {5 }},
@@ -1233,7 +1233,7 @@ TEST(VTimestampFunctionsTest, dayname_test) {
12331233 }
12341234
12351235 {
1236- InputTypeSet input_types = {PrimitiveType::TYPE_DATETIME };
1236+ InputTypeSet input_types = {PrimitiveType::TYPE_DATETIMEV2 };
12371237
12381238 DataSet data_set = {
12391239 {{std::string (" 2007-02-03 00:00:00" )}, std::string (" Saturday" )},
0 commit comments