You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "hailong wang (Jira)" <ji...@apache.org> on 2020/01/20 03:47:00 UTC
[jira] [Commented] (FLINK-15677) TableSource#explainSource should
return the field names from getProducedDataType instead of getTableSchema
[ https://issues.apache.org/jira/browse/FLINK-15677?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17019211#comment-17019211 ]
hailong wang commented on FLINK-15677:
--------------------------------------
My idea is simple, just replace
{code:java}
TableConnectorUtils.generateRuntimeName(getClass(), getTableSchema().getFieldNames());
{code}
with
{code:java}
List<String> fieldNames = ((RowType) getProducedDataType().getLogicalType()).getFieldNames(); return TableConnectorUtils.generateRuntimeName( getClass(), fieldNames.stream().toArray(String[]::new));
{code}
Are there some thing that have not been considered? [~lzljs3620320] [~jark]
> TableSource#explainSource should return the field names from getProducedDataType instead of getTableSchema
> ----------------------------------------------------------------------------------------------------------
>
> Key: FLINK-15677
> URL: https://issues.apache.org/jira/browse/FLINK-15677
> Project: Flink
> Issue Type: Improvement
> Components: Table SQL / Planner
> Affects Versions: 1.10.0
> Reporter: hailong wang
> Priority: Major
> Fix For: 1.11.0
>
>
> For the fields push down, the final fieldNames of tablesource are not consistent with FieldNames from TableSchema. So we should return the field names from getProducedDataType instead of getTableSchema.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)