You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Jark Wu (Jira)" <ji...@apache.org> on 2021/01/12 12:24:00 UTC

[jira] [Closed] (FLINK-20907) Table API documentation promotes deprecated syntax

     [ https://issues.apache.org/jira/browse/FLINK-20907?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jark Wu closed FLINK-20907.
---------------------------
    Resolution: Fixed

Fixed in
 - master: 057bf7accf9ef766851e306db0d542306d7bbe5e
 - release-1.12: 8ff78f5874feb29df136b3c889cdecf139a2e948

> Table API documentation promotes deprecated syntax
> --------------------------------------------------
>
>                 Key: FLINK-20907
>                 URL: https://issues.apache.org/jira/browse/FLINK-20907
>             Project: Flink
>          Issue Type: Improvement
>          Components: Documentation
>    Affects Versions: 1.12.0
>            Reporter: Svend Vanderveken
>            Assignee: Svend Vanderveken
>            Priority: Minor
>              Labels: pull-request-available
>             Fix For: 1.13.0, 1.12.2
>
>
> Code examples in java, scala and python showing the overall structure of a Flink Table API job are all using the `tableEnv.connect(...)` syntax, which is deprecated.
> As visible here:
> [https://ci.apache.org/projects/flink/flink-docs-release-1.12/dev/table/common.html#structure-of-table-api-and-sql-programs]
> For example:
> {code:java}
> // create a TableEnvironment for specific planner batch or streaming
> TableEnvironment tableEnv = ...; // see "Create a TableEnvironment" section
> // create a Table
> tableEnv.connect(...).createTemporaryTable("table1");
> // register an output Table
> tableEnv.connect(...).createTemporaryTable("outputTable");
> // create a Table object from a Table API query
> Table tapiResult = tableEnv.from("table1").select(...);
> {code}
> This is quite missleading since this is one of the first place where Table API code is shown to the reader.
> I suggest I send a small PR to show the {{executeSql()}} syntax, which is now preferred.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)