godfreyhe commented on a change in pull request #12049:
URL: https://github.com/apache/flink/pull/12049#discussion_r422826714



##########
File path: 
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/delegation/Planner.java
##########
@@ -74,14 +76,22 @@
         */
        List<Transformation<?>> translate(List<ModifyOperation> 
modifyOperations);
 
+       /**
+        * Creates a {@link SelectTableSink} for a select query.
+        *
+        * @param tableSchema the table schema of select result.
+        * @return The {@link SelectTableSink} for the select query.
+        */
+       SelectTableSink createSelectTableSink(TableSchema tableSchema);

Review comment:
       I think it does not work. because collect Iterator is generated in 
`TableSink` (e.g. the iterator is created when `StreamSelectTableSink` is 
created.) and we need to put it into `TableResult` in 
`TableEnvironmentImpl#executeOperation`. now we make sure that 
`SelectTableSink` instance is not changed after created, so we can get the 
correct Iterator. 
   
   while we can't get collect Iterator from the dedicated `ModifyOperation`.




----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to