Saranviveka opened a new issue, #6853:
URL: https://github.com/apache/iceberg/issues/6853

   spark.sql("""CREATE TABLE iceberg.glue_catalog.iceberg_table ( order_id 
bigint,
   customer_id bigint, order_amount DECIMAL(10,2), category string, trans_ts 
Timestamp)
   USING iceberg
   location 's3://xxx/yyyy/iceberg_table'
   PARTITIONED BY (bucket(5, order_id), date(trans_ts))
   TBLPROPERTIES ('format-version' = '2') """)
   
   spark.sql("""ALTER TABLE iceberg.glue_catalog.iceberg_table ADD PARTITION 
FIELD years(trans_ts)  """)
   spark.sql("""ALTER TABLE iceberg.glue_catalog.iceberg_table ADD PARTITION 
FIELD months(trans_ts)  """)
   spark.sql("""ALTER TABLE iceberg.glue_catalog.iceberg_table ADD PARTITION 
FIELD hours(trans_ts) """)
   spark.sql("""ALTER TABLE iceberg.glue_catalog.iceberg_table ADD PARTITION 
FIELD category """)
   
   Greater than works
   trino> select * from iceberg.glue_catalog.iceberg_table where trans_ts > 
date'2019-06-12';
    order_id | customer_id | order_amount | category |            trans_ts
   
----------+-------------+--------------+----------+--------------------------------
       10001 |           1 |         6.17 | soap     | 2019-06-13 
17:22:30.000000 UTC
   
   Between works well
   trino> select * from iceberg.glue_catalog.iceberg_table where trans_ts 
BETWEEN date'2019-06-12' and date'2019-06-14' ;
    order_id | customer_id | order_amount | category |            trans_ts
   
----------+-------------+--------------+----------+--------------------------------
       10001 |           1 |         6.17 | soap     | 2019-06-13 
17:22:30.000000 UTC
   
   Equality doesn't work
   trino>select * from iceberg.glue_catalog.iceberg_table where 
trans_ts=date'2019-06-13';
    order_id | customer_id | order_amount | category | trans_ts
   ----------+-------------+--------------+----------+----------
   (0 rows)
   
   


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