Skip to content

Commit

Permalink
Make all output one Row.
Browse files Browse the repository at this point in the history
  • Loading branch information
concretevitamin committed Jun 7, 2014
1 parent 439c6ab commit 4318fd7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ import org.apache.spark.sql.catalyst.expressions.{GenericRow, Attribute}
case class ExplainCommandPhysical(child: SparkPlan)
(@transient context: SQLContext) extends UnaryNode {
def execute(): RDD[Row] = {
val lines = child.toString.split("\n").map(s => new GenericRow(Array[Any](s)))
context.sparkContext.parallelize(lines)
val planString = new GenericRow(Array[Any](child.toString))
context.sparkContext.parallelize(Seq(planString))
}

def output: Seq[Attribute] = child.output // right thing to do?
Expand Down

0 comments on commit 4318fd7

Please sign in to comment.