Github user marmbrus commented on a diff in the pull request:

    https://github.com/apache/spark/pull/7417#discussion_r38992862
  
    --- Diff: 
sql/core/src/main/scala/org/apache/spark/sql/execution/SparkStrategies.scala ---
    @@ -267,12 +267,32 @@ private[sql] abstract class SparkStrategies extends 
QueryPlanner[SparkPlan] {
       }
     
       object CartesianProduct extends Strategy {
    +    def createCartesianProduct(left: LogicalPlan, right: LogicalPlan): 
SparkPlan = {
    +      // If plan can broadcast we use BroadcastNestedLoopJoin, as we know 
for inner join with true
    +      // condition is same as Cartesian.
    +      // For CartesianProduct we will use the small size plan as cartesian 
left rdd.
    +      if (right.statistics.sizeInBytes <= left.statistics.sizeInBytes) {
    +        right match {
    +          case CanBroadcast(right) => 
joins.BroadcastNestedLoopJoin(planLater(left),
    --- End diff --
    
    the line wrapping here is off.  if you have to wrap, don't leave anything 
on the line of the case statement.  if you have to wrap one parameter, wrap 
them all.


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to