[ https://issues.apache.org/jira/browse/SPARK-22626?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16276988#comment-16276988 ]
Apache Spark commented on SPARK-22626: -------------------------------------- User 'wzhfy' has created a pull request for this issue: https://github.com/apache/spark/pull/19880 > Wrong Hive table statistics may trigger OOM if enables CBO > ---------------------------------------------------------- > > Key: SPARK-22626 > URL: https://issues.apache.org/jira/browse/SPARK-22626 > Project: Spark > Issue Type: Sub-task > Components: SQL > Affects Versions: 2.3.0 > Reporter: Yuming Wang > Assignee: Yuming Wang > Priority: Minor > Fix For: 2.3.0 > > > How to reproduce: > {code} > bin/spark-shell --conf spark.sql.cbo.enabled=true > {code} > {code:java} > import org.apache.spark.sql.execution.joins.BroadcastHashJoinExec > spark.sql("CREATE TABLE small (c1 bigint) TBLPROPERTIES ('numRows'='3', > 'rawDataSize'='600','totalSize'='800')") > // Big table with wrong statistics, numRows=0 > spark.sql("CREATE TABLE big (c1 bigint) TBLPROPERTIES ('numRows'='0', > 'rawDataSize'='60000000000', 'totalSize'='8000000000000')") > val plan = spark.sql("select * from small t1 join big t2 on (t1.c1 = > t2.c1)").queryExecution.executedPlan > val buildSide = > plan.children.head.asInstanceOf[BroadcastHashJoinExec].buildSide > println(buildSide) > {code} > The result is {{BuildRight}}, but the right side is the big table. -- This message was sent by Atlassian JIRA (v6.4.14#64029) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org