Skip to content
Snippets Groups Projects
Commit 52fbdc2d authored by Daoyuan Wang's avatar Daoyuan Wang Committed by Michael Armbrust
Browse files

[Spark-3222] [SQL] Cross join support in HiveQL

We can simple treat cross join as inner join without join conditions.

Author: Daoyuan Wang <daoyuan.wang@intel.com>
Author: adrian-wang <daoyuanwong@gmail.com>

Closes #2124 from adrian-wang/crossjoin and squashes the following commits:

8c9b7c5 [Daoyuan Wang] add a test
7d47bbb [adrian-wang] add cross join support for hql
parent 62f5009f
No related branches found
No related tags found
No related merge requests found
...@@ -310,6 +310,7 @@ class HiveCompatibilitySuite extends HiveQueryFileTest with BeforeAndAfter { ...@@ -310,6 +310,7 @@ class HiveCompatibilitySuite extends HiveQueryFileTest with BeforeAndAfter {
"create_nested_type", "create_nested_type",
"create_skewed_table1", "create_skewed_table1",
"create_struct_table", "create_struct_table",
"cross_join",
"ct_case_insensitive", "ct_case_insensitive",
"database_location", "database_location",
"database_properties", "database_properties",
......
...@@ -772,6 +772,7 @@ private[hive] object HiveQl { ...@@ -772,6 +772,7 @@ private[hive] object HiveQl {
val joinType = joinToken match { val joinType = joinToken match {
case "TOK_JOIN" => Inner case "TOK_JOIN" => Inner
case "TOK_CROSSJOIN" => Inner
case "TOK_RIGHTOUTERJOIN" => RightOuter case "TOK_RIGHTOUTERJOIN" => RightOuter
case "TOK_LEFTOUTERJOIN" => LeftOuter case "TOK_LEFTOUTERJOIN" => LeftOuter
case "TOK_FULLOUTERJOIN" => FullOuter case "TOK_FULLOUTERJOIN" => FullOuter
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment