You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by tw...@apache.org on 2019/03/05 09:14:55 UTC
[flink] branch master updated: [hotfix][table-api] Add docs to
over-windowed table's select()
This is an automated email from the ASF dual-hosted git repository.
twalthr pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink.git
The following commit(s) were added to refs/heads/master by this push:
new a2a9c5c [hotfix][table-api] Add docs to over-windowed table's select()
a2a9c5c is described below
commit a2a9c5c6398c8b3213ff07cd982b252b6c104053
Author: Timo Walther <tw...@apache.org>
AuthorDate: Tue Mar 5 10:04:51 2019 +0100
[hotfix][table-api] Add docs to over-windowed table's select()
---
.../scala/org/apache/flink/table/api/table.scala | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/api/table.scala b/flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/api/table.scala
index 8638650..7c0777c 100644
--- a/flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/api/table.scala
+++ b/flink-table/flink-table-planner/src/main/scala/org/apache/flink/table/api/table.scala
@@ -1228,6 +1228,16 @@ class OverWindowedTable(
private[flink] val table: Table,
private[flink] val overWindows: Array[OverWindow]) {
+ /**
+ * Performs a selection operation on an over-windowed table. Similar to an SQL SELECT statement.
+ * The field expressions can contain complex expressions and aggregations.
+ *
+ * Example:
+ *
+ * {{{
+ * overWindowedTable.select('c, 'b.count over 'ow, 'e.sum over 'ow)
+ * }}}
+ */
def select(fields: Expression*): Table = {
val expandedFields = expandProjectList(
fields,
@@ -1252,6 +1262,16 @@ class OverWindowedTable(
)
}
+ /**
+ * Performs a selection operation on an over-windowed table. Similar to an SQL SELECT statement.
+ * The field expressions can contain complex expressions and aggregations.
+ *
+ * Example:
+ *
+ * {{{
+ * overWindowedTable.select("c, b.count over ow, e.sum over ow")
+ * }}}
+ */
def select(fields: String): Table = {
val fieldExprs = ExpressionParser.parseExpressionList(fields)
//get the correct expression for AggFunctionCall