Skip to content

Commit aa78690

Browse files
committed
Re-gen postgreSQL/timestamp.sql
1 parent b581a46 commit aa78690

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

sql/core/src/test/resources/sql-tests/inputs/postgreSQL/timestamp.sql

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,21 +18,21 @@ CREATE TABLE TIMESTAMP_TBL (d1 timestamp) USING parquet;
1818

1919
-- PostgreSQL implicitly casts string literals to data with timestamp types, but
2020
-- Spark does not support that kind of implicit casts.
21-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('now'));
21+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'now');
2222
-- SELECT pg_sleep(0.1);
2323

2424
-- BEGIN;
2525

2626
-- PostgreSQL implicitly casts string literals to data with timestamp types, but
2727
-- Spark does not support that kind of implicit casts.
28-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('now'));
29-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('today'));
30-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('yesterday'));
31-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('tomorrow'));
28+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'now');
29+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'today');
30+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'yesterday');
31+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'tomorrow');
3232
-- time zone should be ignored by this data type
33-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('tomorrow EST'));
33+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'tomorrow EST');
3434
-- [SPARK-29024] Ignore case while resolving time zones
35-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('tomorrow Zulu'));
35+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'tomorrow Zulu');
3636

3737
SELECT count(*) AS One FROM TIMESTAMP_TBL WHERE d1 = timestamp 'today';
3838
SELECT count(*) AS Three FROM TIMESTAMP_TBL WHERE d1 = timestamp 'tomorrow';
@@ -60,7 +60,7 @@ TRUNCATE TABLE TIMESTAMP_TBL;
6060
-- INSERT INTO TIMESTAMP_TBL VALUES ('infinity');
6161
-- PostgreSQL implicitly casts string literals to data with timestamp types, but
6262
-- Spark does not support that kind of implicit casts.
63-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('epoch'));
63+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'epoch');
6464
-- [SPARK-27923] Spark SQL insert there obsolete special values to NULL
6565
-- Obsolete special values
6666
-- INSERT INTO TIMESTAMP_TBL VALUES ('invalid');

sql/core/src/test/resources/sql-tests/results/postgreSQL/timestamp.sql.out

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,55 +11,55 @@ struct<>
1111

1212

1313
-- !query
14-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('now'))
14+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'now')
1515
-- !query schema
1616
struct<>
1717
-- !query output
1818

1919

2020

2121
-- !query
22-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('now'))
22+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'now')
2323
-- !query schema
2424
struct<>
2525
-- !query output
2626

2727

2828

2929
-- !query
30-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('today'))
30+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'today')
3131
-- !query schema
3232
struct<>
3333
-- !query output
3434

3535

3636

3737
-- !query
38-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('yesterday'))
38+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'yesterday')
3939
-- !query schema
4040
struct<>
4141
-- !query output
4242

4343

4444

4545
-- !query
46-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('tomorrow'))
46+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'tomorrow')
4747
-- !query schema
4848
struct<>
4949
-- !query output
5050

5151

5252

5353
-- !query
54-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('tomorrow EST'))
54+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'tomorrow EST')
5555
-- !query schema
5656
struct<>
5757
-- !query output
5858

5959

6060

6161
-- !query
62-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('tomorrow Zulu'))
62+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'tomorrow Zulu')
6363
-- !query schema
6464
struct<>
6565
-- !query output
@@ -99,7 +99,7 @@ struct<>
9999

100100

101101
-- !query
102-
INSERT INTO TIMESTAMP_TBL VALUES (timestamp('epoch'))
102+
INSERT INTO TIMESTAMP_TBL VALUES (timestamp'epoch')
103103
-- !query schema
104104
struct<>
105105
-- !query output

0 commit comments

Comments
 (0)