flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From twalthr <...@git.apache.org>
Subject [GitHub] flink pull request: [FLINK-2951] [Table API] add union operator to...
Date Thu, 05 Nov 2015 15:59:32 GMT
Github user twalthr commented on a diff in the pull request:

    https://github.com/apache/flink/pull/1315#discussion_r44028753
  
    --- Diff: flink-staging/flink-table/src/main/scala/org/apache/flink/api/table/Table.scala
---
    @@ -243,5 +243,29 @@ case class Table(private[flink] val operation: PlanNode) {
         this.copy(operation = Join(operation, right.operation))
       }
     
    +  /**
    +   * Union two[[Table]]s. Similar to an SQL UNION ALL. The fields of the two union operations
    +   * must fully overlap.
    +   *
    +   * Example:
    +   *
    +   * {{{
    +   *   left.unionAll(right)
    +   * }}}
    +   */
    +  def unionAll(right: Table): Table = {
    +    val leftInputFields = operation.outputFields.toSet
    +    val rightInputFields = right.operation.outputFields.toSet
    --- End diff --
    
    Thanks for implementing my feedback. Unfortunately, you introduced a new bug. Can you
remove the two `.toSet`? Otherwise the order of the fields will not be considered in your
equality check, which is wrong. After that I will merge your PR ;-)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message