[
https://issues.apache.org/jira/browse/FLINK-6955?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kurt Young closed FLINK-6955.
-----------------------------
Resolution: Unresolved
> Add operation log for Table
> ---------------------------
>
> Key: FLINK-6955
> URL: https://issues.apache.org/jira/browse/FLINK-6955
> Project: Flink
> Issue Type: Improvement
> Components: Table API & SQL
> Reporter: kaibo.zhou
> Assignee: kaibo.zhou
> Priority: Major
>
> In some of the actual production scenarios, the operation of the Table is
> very complicated, will go through a number of steps. For example, the Table
> object will be generated at the beginning of the program, in the process of
> running will be passed to different modules, each module will do some
> operations for the Table, such as union, join or filter. At the end of the
> program will call writeToSink or other operations.
> Hoping to record the operation about Table and can print out.
> eg:
> {code}
> val table1 = StreamTestData.getSmall3TupleDataStream(env).toTable(tEnv,
> 'a, 'b, 'c)
> val table2 = StreamTestData.get5TupleDataStream(env).toTable(tEnv, 'a,
> 'b, 'd, 'c, 'e)
> val unionDs = table1.unionAll(table2.select('a, 'b, 'c)).filter('b <
> 2).select('c)
> val results = unionDs.toDataStream[Row]
>
> val result = tEnv.getLog
> val expected =
> "UnnamedTable$1 = UnnamedTable$0.select('a, 'b, 'c)\n" +
> "UnnamedTable$5 = UnnamedTable$2.unionAll(UnnamedTable$1)\n" +
> " .filter('b < 2)\n" +
> " .select('c)\n"
> assertEquals(expected, result)
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)