apache / iceberg

Apache Iceberg
https://iceberg.apache.org/
Apache License 2.0
6.49k stars 2.24k forks source link

the `where` sql in rewriteDataFilesAction is always case sensitive #11438

Open ludlows opened 3 weeks ago

ludlows commented 3 weeks ago

Apache Iceberg version

1.6.1 (latest release)

Query engine

Spark

Please describe the bug 🐞

given an iceberg table created by the following sql:

CREATE TABLE icbtest.test0(
`pk_id` int,
 val string,
 start_dt string, 
end_dt string
) USING iceberg 
partitioned by (truncate(6, end_dt))
;

after that, we run the rewriteDataFiles procedure by the sql:

set spark.sql.caseSensitive=false;
call my_catalog.system.rewrite_data_files(table=>'icbtest.test0', where => " END_DT  > '202008' ");

the following exception is raised ice-bug

since the where sql is always case sensitive, and set spark.sql.caseSensitive=false does not take effects.

Willingness to contribute