forked from apache/hive
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
HIVE-27513: Iceberg: Fetch task returns wrong results for Timestamp w…
…ith local time zone datatype for Iceberg tables (Sourabh Badhya, reviewed by Ayush Saxena, Denys Kuzmenko) Closes apache#4498
- Loading branch information
1 parent
fad3aae
commit 3bf6395
Showing
5 changed files
with
70 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
iceberg/iceberg-handler/src/test/queries/positive/iceberg_timestamp_with_local_time_zone.q
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
create table ice_ts_4 (id int, ts timestamp with local time zone) stored by iceberg stored as parquet; | ||
insert into ice_ts_4 values (1, cast('2023-07-20 00:00:00' as timestamp with local time zone)); | ||
|
||
set hive.fetch.task.conversion=none; | ||
select * from ice_ts_4; | ||
|
||
set hive.fetch.task.conversion=more; | ||
select * from ice_ts_4; |
34 changes: 34 additions & 0 deletions
34
...rg/iceberg-handler/src/test/results/positive/iceberg_timestamp_with_local_time_zone.q.out
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
PREHOOK: query: create table ice_ts_4 (id int, ts timestamp with local time zone) stored by iceberg stored as parquet | ||
PREHOOK: type: CREATETABLE | ||
PREHOOK: Output: database:default | ||
PREHOOK: Output: default@ice_ts_4 | ||
POSTHOOK: query: create table ice_ts_4 (id int, ts timestamp with local time zone) stored by iceberg stored as parquet | ||
POSTHOOK: type: CREATETABLE | ||
POSTHOOK: Output: database:default | ||
POSTHOOK: Output: default@ice_ts_4 | ||
PREHOOK: query: insert into ice_ts_4 values (1, cast('2023-07-20 00:00:00' as timestamp with local time zone)) | ||
PREHOOK: type: QUERY | ||
PREHOOK: Input: _dummy_database@_dummy_table | ||
PREHOOK: Output: default@ice_ts_4 | ||
POSTHOOK: query: insert into ice_ts_4 values (1, cast('2023-07-20 00:00:00' as timestamp with local time zone)) | ||
POSTHOOK: type: QUERY | ||
POSTHOOK: Input: _dummy_database@_dummy_table | ||
POSTHOOK: Output: default@ice_ts_4 | ||
PREHOOK: query: select * from ice_ts_4 | ||
PREHOOK: type: QUERY | ||
PREHOOK: Input: default@ice_ts_4 | ||
PREHOOK: Output: hdfs://### HDFS PATH ### | ||
POSTHOOK: query: select * from ice_ts_4 | ||
POSTHOOK: type: QUERY | ||
POSTHOOK: Input: default@ice_ts_4 | ||
POSTHOOK: Output: hdfs://### HDFS PATH ### | ||
1 2023-07-20 00:00:00.0 US/Pacific | ||
PREHOOK: query: select * from ice_ts_4 | ||
PREHOOK: type: QUERY | ||
PREHOOK: Input: default@ice_ts_4 | ||
PREHOOK: Output: hdfs://### HDFS PATH ### | ||
POSTHOOK: query: select * from ice_ts_4 | ||
POSTHOOK: type: QUERY | ||
POSTHOOK: Input: default@ice_ts_4 | ||
POSTHOOK: Output: hdfs://### HDFS PATH ### | ||
1 2023-07-20 00:00:00.0 US/Pacific |