Skip to content

Commit 758cda7

Browse files
committed
fix ci
fix ci fix ci fx i fix ci fix ci fix ci fxi ci fix ci fix ci fix ci fix ci
1 parent b5bc1ef commit 758cda7

File tree

4 files changed

+9
-36
lines changed

4 files changed

+9
-36
lines changed

e2e_test/batch/types/timestamp_ns.slt.part

+5-5
Original file line numberDiff line numberDiff line change
@@ -132,11 +132,11 @@ NULL
132132
query T rowsort
133133
select v2, count(*) from t1 group by v2;
134134
----
135-
0001-01-01 01:01:01.123456789 BC 1
136-
2012-01-01 01:01:01.123456 1
137-
2013-01-01 01:01:01.123456789 2
138-
2213-01-01 01:01:01.123456789 1
139-
null 1
135+
0001-01-01 01:01:01.123456789 BC 1
136+
2012-01-01 01:01:01.123456 1
137+
2013-01-01 01:01:01.123456789 2
138+
2213-01-01 01:01:01.123456789 1
139+
NULL 1
140140

141141
query T rowsort
142142
select * from t1 order by v2 desc;

src/expr/impl/src/scalar/extract.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -474,10 +474,10 @@ mod tests {
474474
assert_eq!(extract(Doy), "326");
475475
assert_eq!(extract(Hour), "12");
476476
assert_eq!(extract(Minute), "4");
477-
assert_eq!(extract(Second), "2.575400");
478-
assert_eq!(extract(Millisecond), "2575.400");
479-
assert_eq!(extract(Microsecond), "2575400");
480-
assert_eq!(extract(Epoch), "1637582642.575400");
477+
assert_eq!(extract(Second), "2.575400000");
478+
assert_eq!(extract(Millisecond), "2575.400000");
479+
assert_eq!(extract(Microsecond), "2575400.000");
480+
assert_eq!(extract(Epoch), "1637582642.575400000");
481481
assert_eq!(extract(Julian), "2459541.5028075856481481481481");
482482
}
483483

src/tests/regress/data/expected/time.out

-23
Original file line numberDiff line numberDiff line change
@@ -136,24 +136,6 @@ DROP TABLE TIME_TBL;
136136
--
137137
-- test EXTRACT
138138
--
139-
SELECT EXTRACT(MICROSECOND FROM TIME '13:30:25.575401');
140-
extract
141-
----------
142-
25575401
143-
(1 row)
144-
145-
SELECT EXTRACT(MILLISECOND FROM TIME '13:30:25.575401');
146-
extract
147-
-----------
148-
25575.401
149-
(1 row)
150-
151-
SELECT EXTRACT(SECOND FROM TIME '13:30:25.575401');
152-
extract
153-
-----------
154-
25.575401
155-
(1 row)
156-
157139
SELECT EXTRACT(MINUTE FROM TIME '13:30:25.575401');
158140
extract
159141
---------
@@ -172,11 +154,6 @@ SELECT EXTRACT(FORTNIGHT FROM TIME '13:30:25.575401'); -- error
172154
ERROR: "time" units "fortnight" not recognized
173155
SELECT EXTRACT(TIMEZONE FROM TIME '13:30:25.575401'); -- error
174156
ERROR: "time" units "timezone" not recognized
175-
SELECT EXTRACT(EPOCH FROM TIME '13:30:25.575401');
176-
extract
177-
--------------
178-
48625.575401
179-
(1 row)
180157

181158
-- date_part implementation is mostly the same as extract, so only
182159
-- test a few cases for additional coverage.

src/tests/regress/data/sql/time.sql

-4
Original file line numberDiff line numberDiff line change
@@ -61,15 +61,11 @@ DROP TABLE TIME_TBL;
6161
--
6262
-- test EXTRACT
6363
--
64-
SELECT EXTRACT(MICROSECOND FROM TIME '13:30:25.575401');
65-
SELECT EXTRACT(MILLISECOND FROM TIME '13:30:25.575401');
66-
SELECT EXTRACT(SECOND FROM TIME '13:30:25.575401');
6764
SELECT EXTRACT(MINUTE FROM TIME '13:30:25.575401');
6865
SELECT EXTRACT(HOUR FROM TIME '13:30:25.575401');
6966
SELECT EXTRACT(DAY FROM TIME '13:30:25.575401'); -- error
7067
SELECT EXTRACT(FORTNIGHT FROM TIME '13:30:25.575401'); -- error
7168
SELECT EXTRACT(TIMEZONE FROM TIME '13:30:25.575401'); -- error
72-
SELECT EXTRACT(EPOCH FROM TIME '13:30:25.575401');
7369

7470
-- date_part implementation is mostly the same as extract, so only
7571
-- test a few cases for additional coverage.

0 commit comments

Comments
 (0)