StarRocks / starrocks-connector-for-apache-flink

Apache License 2.0
194 stars 162 forks source link

[Enhancement] Support to map a subset of StarRocks columns to Flink source table #352

Closed banmoy closed 7 months ago

banmoy commented 7 months ago

What type of PR is this:

Which issues of this PR fixes :

Fixes # Currently columns between Flink schema and StarRocks schema must be same. It's not easy to use if the StarRocks table has thousands of columns, but the user only wants to read some columns of it. This PR supports to define the Flink source table only with some columns of StarRocks table that need to read. For example, StarRocks schema

CREATE TABLE t (
    c0 INT,
    c1 FLOAT,
    c3 STRING
);

If you just want to read c0 and c3, you can define flink source table as follows. Before this PR, must include all columns

CREATE TABLE t (
    c0 INT,
    c3 STRING
) WITH (
  ......
)

Problem Summary(Required) :

Checklist: