Skip to content

Commit

Permalink
[hotfix][docs][examples] Add missing semicolons
Browse files Browse the repository at this point in the history
  • Loading branch information
sv3ndk committed Mar 2, 2021
1 parent 4542abb commit 7c62178
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
20 changes: 10 additions & 10 deletions docs/content.zh/docs/dev/table/tableApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ The Java Table API is enabled by importing `org.apache.flink.table.api.java.*`.
For the Expression DSL it is also necessary to import static `org.apache.flink.table.api.Expressions.*`

```java
import org.apache.flink.table.api.*
import org.apache.flink.table.api.*;

import static org.apache.flink.table.api.Expressions.*
import static org.apache.flink.table.api.Expressions.*;

EnvironmentSettings settings = EnvironmentSettings
.newInstance()
Expand Down Expand Up @@ -1131,7 +1131,7 @@ tableEnv.registerFunction("rates", rates);
// join with "Orders" based on the time attribute and key
Table orders = tableEnv.from("Orders");
Table result = orders
.joinLateral(call("rates", $("o_proctime")), $("o_currency").isEqual($("r_currency")))
.joinLateral(call("rates", $("o_proctime")), $("o_currency").isEqual($("r_currency")));
{{< /tab >}}
{{< tabs "Scala" >}}
```scala
Expand Down Expand Up @@ -2099,16 +2099,16 @@ Note: Currently, all aggregation functions in the same select() call must be com
{{< tab "Java" >}}
```java
// Bounded Event-time over window (assuming an event-time attribute "rowtime")
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(lit(1).minutes()).as("w"))
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(lit(1).minutes()).as("w"));

// Bounded Processing-time over window (assuming a processing-time attribute "proctime")
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(lit(1).minutes()).as("w"))
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(lit(1).minutes()).as("w"));

// Bounded Event-time Row-count over window (assuming an event-time attribute "rowtime")
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(rowInterval(10)).as("w"))
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(rowInterval(10)).as("w"));

// Bounded Processing-time Row-count over window (assuming a processing-time attribute "proctime")
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(rowInterval(10)).as("w"))
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(rowInterval(10)).as("w"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down Expand Up @@ -2173,7 +2173,7 @@ ScalarFunction func = new MyMapFunction();
tableEnv.registerFunction("func", func);

Table table = input
.map(call("func", $("c")).as("a", "b"))
.map(call("func", $("c")).as("a", "b"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down Expand Up @@ -2227,7 +2227,7 @@ TableFunction func = new MyFlatMapFunction();
tableEnv.registerFunction("func", func);

Table table = input
.flatMap(call("func", $("c")).as("a", "b"))
.flatMap(call("func", $("c")).as("a", "b"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down Expand Up @@ -2310,7 +2310,7 @@ tableEnv.registerFunction("myAggFunc", myAggFunc);
Table table = input
.groupBy($("key"))
.aggregate(call("myAggFunc", $("a")).as("x", "y"))
.select($("key"), $("x"), $("y"))
.select($("key"), $("x"), $("y"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down
20 changes: 10 additions & 10 deletions docs/content/docs/dev/table/tableApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ The Java Table API is enabled by importing `org.apache.flink.table.api.java.*`.
For the Expression DSL it is also necessary to import static `org.apache.flink.table.api.Expressions.*`

```java
import org.apache.flink.table.api.*
import org.apache.flink.table.api.*;

import static org.apache.flink.table.api.Expressions.*
import static org.apache.flink.table.api.Expressions.*;

EnvironmentSettings settings = EnvironmentSettings
.newInstance()
Expand Down Expand Up @@ -1131,7 +1131,7 @@ tableEnv.registerFunction("rates", rates);
// join with "Orders" based on the time attribute and key
Table orders = tableEnv.from("Orders");
Table result = orders
.joinLateral(call("rates", $("o_proctime")), $("o_currency").isEqual($("r_currency")))
.joinLateral(call("rates", $("o_proctime")), $("o_currency").isEqual($("r_currency")));
{{< /tab >}}
{{< tabs "Scala" >}}
```scala
Expand Down Expand Up @@ -2099,16 +2099,16 @@ Note: Currently, all aggregation functions in the same select() call must be com
{{< tab "Java" >}}
```java
// Bounded Event-time over window (assuming an event-time attribute "rowtime")
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(lit(1).minutes()).as("w"))
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(lit(1).minutes()).as("w"));

// Bounded Processing-time over window (assuming a processing-time attribute "proctime")
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(lit(1).minutes()).as("w"))
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(lit(1).minutes()).as("w"));

// Bounded Event-time Row-count over window (assuming an event-time attribute "rowtime")
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(rowInterval(10)).as("w"))
.window(Over.partitionBy($("a")).orderBy($("rowtime")).preceding(rowInterval(10)).as("w"));

// Bounded Processing-time Row-count over window (assuming a processing-time attribute "proctime")
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(rowInterval(10)).as("w"))
.window(Over.partitionBy($("a")).orderBy($("proctime")).preceding(rowInterval(10)).as("w"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down Expand Up @@ -2173,7 +2173,7 @@ ScalarFunction func = new MyMapFunction();
tableEnv.registerFunction("func", func);

Table table = input
.map(call("func", $("c")).as("a", "b"))
.map(call("func", $("c")).as("a", "b"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down Expand Up @@ -2227,7 +2227,7 @@ TableFunction func = new MyFlatMapFunction();
tableEnv.registerFunction("func", func);

Table table = input
.flatMap(call("func", $("c")).as("a", "b"))
.flatMap(call("func", $("c")).as("a", "b"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down Expand Up @@ -2310,7 +2310,7 @@ tableEnv.registerFunction("myAggFunc", myAggFunc);
Table table = input
.groupBy($("key"))
.aggregate(call("myAggFunc", $("a")).as("x", "y"))
.select($("key"), $("x"), $("y"))
.select($("key"), $("x"), $("y"));
```
{{< /tab >}}
{{< tab "Scala" >}}
Expand Down

0 comments on commit 7c62178

Please sign in to comment.