Skip to content

Commit

Permalink
add golden files for leftsemijoin
Browse files Browse the repository at this point in the history
  • Loading branch information
adrian-wang committed May 21, 2014
1 parent 83a3c8a commit 8d4a121
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 2 deletions.
Expand Up @@ -18,7 +18,7 @@
package org.apache.spark.sql.catalyst.plans.logical

import org.apache.spark.sql.catalyst.expressions._
import org.apache.spark.sql.catalyst.plans.JoinType
import org.apache.spark.sql.catalyst.plans.{LeftSemi, JoinType}
import org.apache.spark.sql.catalyst.types._

case class Project(projectList: Seq[NamedExpression], child: LogicalPlan) extends UnaryNode {
Expand Down Expand Up @@ -81,7 +81,12 @@ case class Join(
condition: Option[Expression]) extends BinaryNode {

def references = condition.map(_.references).getOrElse(Set.empty)
def output = left.output ++ right.output
def output = joinType match {
case LeftSemi =>
left.output
case _ =>
left.output ++ right.output
}
}

case class InsertIntoTable(
Expand Down
@@ -0,0 +1,4 @@
Hank 2
Hank 2
Joe 2
Joe 2
Empty file.
Empty file.
@@ -0,0 +1,4 @@
Hank 2
Hank 2
Joe 2
Joe 2
@@ -0,0 +1,2 @@
2 Tie
2 Tie

0 comments on commit 8d4a121

Please sign in to comment.