[
https://issues.apache.org/jira/browse/FLINK-22260?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Dawid Wysakowicz updated FLINK-22260:
-------------------------------------
Affects Version/s: (was: 1.13.0)
> Source schema in CREATE TABLE LIKE statements is not inferred correctly
> -----------------------------------------------------------------------
>
> Key: FLINK-22260
> URL: https://issues.apache.org/jira/browse/FLINK-22260
> Project: Flink
> Issue Type: Bug
> Components: Table SQL / API
> Reporter: Ingo Bürk
> Assignee: Ingo Bürk
> Priority: Blocker
> Fix For: 1.13.0
>
>
> When using a LIKE statement such as in the following (assume some_sink and
> some_source to be two tables with the same schema)
> {code:java}
> CREATE TEMPORARY TABLE b LIKE some_sink
> INSERT INTO b SELECT * FROM some_source{code}
> the source schema for the INSERT operation is not actually inferred
> correctly, causing the entire query to fail:
> {quote}org.apache.flink.table.api.ValidationException: Column types of query
> result and sink for registered table 'default.default.b' do not match.
> Cause: Different number of columns.
> Query schema: [name: STRING, ts: TIMESTAMP(3) *ROWTIME*]
> Sink schema: []
> {quote}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)