flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chesnay Schepler (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (FLINK-4827) The scala example of SQL on Streaming Tables with wrong variable name in flink document
Date Fri, 14 Oct 2016 12:14:20 GMT

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

Chesnay Schepler updated FLINK-4827:
------------------------------------
    Fix Version/s:     (was: 1.1.3)
                   1.2.0

> The scala example of SQL on Streaming Tables  with wrong variable name in flink document
> ----------------------------------------------------------------------------------------
>
>                 Key: FLINK-4827
>                 URL: https://issues.apache.org/jira/browse/FLINK-4827
>             Project: Flink
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 1.1.0, 1.1.2
>            Reporter: yuemeng
>            Priority: Minor
>             Fix For: 1.2.0
>
>         Attachments: 0001-The-scala-example-of-SQL-on-Streaming-Tables-with-wr.patch
>
>
> val env = StreamExecutionEnvironment.getExecutionEnvironment
> val tEnv = TableEnvironment.getTableEnvironment(env)
> // read a DataStream from an external source
> val ds: DataStream[(Long, String, Integer)] = env.addSource(...)
> // register the DataStream under the name "Orders"
> tableEnv.registerDataStream("Orders", ds, 'user, 'product, 'amount)
> // run a SQL query on the Table and retrieve the result as a new Table
> val result = tableEnv.sql(
>   "SELECT product, amount FROM Orders WHERE product LIKE '%Rubber%'")
> There is no variable named tableEnv had defined ,Only tEnv defined here



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message