[ 
https://issues.apache.org/jira/browse/HIVE-25062?focusedWorklogId=589917&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-589917
 ]

ASF GitHub Bot logged work on HIVE-25062:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 27/Apr/21 18:02
            Start Date: 27/Apr/21 18:02
    Worklog Time Spent: 10m 
      Work Description: pvary opened a new pull request #2228:
URL: https://github.com/apache/hive/pull/2228


   ### What changes were proposed in this pull request?
   Wrap the Record before calculating partitions
   
   ### Why are the changes needed?
   Timestamp/Date needs values converted to long/int respectively to calculate 
partitions
   
   ### Does this PR introduce _any_ user-facing change?
   No
   
   
   ### How was this patch tested?
   Added new unit tests
   


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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

            Worklog Id:     (was: 589917)
    Remaining Estimate: 0h
            Time Spent: 10m

> Iceberg: Fix date partition transform insert issue
> --------------------------------------------------
>
>                 Key: HIVE-25062
>                 URL: https://issues.apache.org/jira/browse/HIVE-25062
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Peter Vary
>            Assignee: Peter Vary
>            Priority: Major
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> {{Repro steps:}}
> {code:java}
> CREATE EXTERNAL TABLE iceberg_hive_part (id int, part_field date)STORED BY 
> 'org.apache.iceberg.mr.hive.HiveIcebergStorageHandler'
> TBLPROPERTIES (
> 'iceberg.mr.table.partition.spec'='{"spec-id":0,"fields":[{"name":"part_year","transform":"year","source-id":1,"field-id":1001}]}'
> ,'write.format.default'='PARQUET'){code}
> {code:java}
> INSERT INTO iceberg_hive_part values(1, cast('2021-04-20' as date))        
> {code}
>  throws:
> {code:java}
> (Not an instance of java.lang.Integer: 2021-04-20){code}
> Add unit tests covering partition transform reads/writes.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to