Hello all, I have found that flink sql client doesn't work with "partition
by" clause.
Is this bug? It's bit weird since when I execute same sql with
tableEnv.executeSql(statement) code it works as expected. Has anyone
tackled this kind of issue? I have tested in flink 1.16.1 version.
Thanks in advance


- This below code only works with executeSql method in table api but not
with sql client cli.

CREATE TABLE source_table

(

    id       STRING,

    status   STRING,

    type     STRING,

    `hour`        INT

) PARTITIONED BY (`hour`) WITH (

      'connector' = 'filesystem',

      'path' = 'hdfs://${our_data_path}month=202307/day=20230714',

      'format' = 'parquet'

      );


SELECT `hour`

FROM source_table

GROUP BY `hour`;



- This below query works both on executeSql method in table api and sql
client query.


CREATE TABLE source_table_2

(

    id       STRING,

    status   STRING,

    type     STRING

) WITH (

      'connector' = 'filesystem',

      'path' = 'hdfs://${out_data_path}/month=202307/day=20230714',

      'format' = 'parquet'

      );


SELECT status

FROM source_table_2

GROUP BY status;



Best,

dongwoo

Reply via email to