dawidwys commented on a change in pull request #8057: [FLINK-12028][table] Add 
`addColumns`,`renameColumns`, `dropColumns` …
URL: https://github.com/apache/flink/pull/8057#discussion_r270818812
 
 

 ##########
 File path: docs/dev/table/tableApi.md
 ##########
 @@ -188,7 +188,50 @@ Table result = orders.select("*");
 {% endhighlight %}
       </td>
     </tr>
-
+  <tr>
+          <td>
+            <strong>AddColumns</strong><br>
+            <span class="label label-primary">Batch</span> <span class="label 
label-primary">Streaming</span>
+          </td>
+          <td>
+          <p>Performs a field add operation.</p>
+{% highlight java %}
+Table orders = tableEnv.scan("Orders");
+Table result = orders.addColumns("concat(c, 'sunny')");
+{% endhighlight %}
+            <p>You can also replace existing fields, the following example 
will replace the 
+            existing `desc` field </p>
+{% highlight java %}
+Table result = orders.addColumns(true, "concat(c, 'sunny') as desc");
+{% endhighlight %}
+          </td>
+        </tr>
+         <tr>
+                  <td>
+                    <strong>DropColumns</strong><br>
+                    <span class="label label-primary">Batch</span> <span 
class="label label-primary">Streaming</span>
+                  </td>
+                  <td>
+                  <p>Performs a field drop operation.</p>
+{% highlight java %}
+Table orders = tableEnv.scan("Orders");
+Table result = orders.dropColumns("b, c");
 
 Review comment:
   I meant, that it would be nice to have that description in docs.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to