cloud-fan commented on a change in pull request #35805:
URL: https://github.com/apache/spark/pull/35805#discussion_r829752673



##########
File path: sql/core/src/test/resources/sql-tests/results/ansi/date.sql.out
##########
@@ -665,158 +665,158 @@ You may get a different result due to the upgrading to 
Spark >= 3.0: Fail to rec
 -- !query
 select dateadd(MICROSECOND, 1001, timestamp'2022-02-25 01:02:03.123')
 -- !query schema
-struct<timestampadd(MICROSECOND, 1001, TIMESTAMP '2022-02-25 
01:02:03.123'):timestamp>
+struct<timestampadd(1001, TIMESTAMP '2022-02-25 01:02:03.123'):timestamp>
 -- !query output
 2022-02-25 01:02:03.124001
 
 
 -- !query
-select date_add(MILLISECOND, -1, timestamp'2022-02-25 01:02:03.456')
+select dateadd(MILLISECOND, -1, timestamp'2022-02-25 01:02:03.456')
 -- !query schema
-struct<timestampadd(MILLISECOND, -1, TIMESTAMP '2022-02-25 
01:02:03.456'):timestamp>
+struct<timestampadd(-1, TIMESTAMP '2022-02-25 01:02:03.456'):timestamp>
 -- !query output
 2022-02-25 01:02:03.455
 
 
 -- !query
 select dateadd(SECOND, 58, timestamp'2022-02-25 01:02:03')
 -- !query schema
-struct<timestampadd(SECOND, 58, TIMESTAMP '2022-02-25 01:02:03'):timestamp>
+struct<timestampadd(58, TIMESTAMP '2022-02-25 01:02:03'):timestamp>

Review comment:
       I think we need to fix `TimestampAdd.sql`. Currently the unit is totally 
missing.

##########
File path: sql/core/src/test/resources/sql-tests/results/ansi/date.sql.out
##########
@@ -665,158 +665,158 @@ You may get a different result due to the upgrading to 
Spark >= 3.0: Fail to rec
 -- !query
 select dateadd(MICROSECOND, 1001, timestamp'2022-02-25 01:02:03.123')
 -- !query schema
-struct<timestampadd(MICROSECOND, 1001, TIMESTAMP '2022-02-25 
01:02:03.123'):timestamp>
+struct<timestampadd(1001, TIMESTAMP '2022-02-25 01:02:03.123'):timestamp>
 -- !query output
 2022-02-25 01:02:03.124001
 
 
 -- !query
-select date_add(MILLISECOND, -1, timestamp'2022-02-25 01:02:03.456')
+select dateadd(MILLISECOND, -1, timestamp'2022-02-25 01:02:03.456')
 -- !query schema
-struct<timestampadd(MILLISECOND, -1, TIMESTAMP '2022-02-25 
01:02:03.456'):timestamp>
+struct<timestampadd(-1, TIMESTAMP '2022-02-25 01:02:03.456'):timestamp>
 -- !query output
 2022-02-25 01:02:03.455
 
 
 -- !query
 select dateadd(SECOND, 58, timestamp'2022-02-25 01:02:03')
 -- !query schema
-struct<timestampadd(SECOND, 58, TIMESTAMP '2022-02-25 01:02:03'):timestamp>
+struct<timestampadd(58, TIMESTAMP '2022-02-25 01:02:03'):timestamp>

Review comment:
       @MaxGekk 




-- 
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.

To unsubscribe, e-mail: [email protected]

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



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to