{"action":"created","issue":{"url":"https://api.github.com/repos/apache/spark/issues/14866","repository_url":"https://api.github.com/repos/apache/spark","labels_url":"https://api.github.com/repos/apache/spark/issues/14866/labels{/name}","comments_url":"https://api.github.com/repos/apache/spark/issues/14866/comments","events_url":"https://api.github.com/repos/apache/spark/issues/14866/events","html_url":"https://github.com/apache/spark/pull/14866","id":173842836,"number":14866,"title":"[SPARK-17298][SQL] Require explicit CROSS join for cartesian products","user":{"login":"srinathshankar","id":3208943,"avatar_url":"https://avatars.githubusercontent.com/u/3208943?v=3","gravatar_id":"","url":"https://api.github.com/users/srinathshankar","html_url":"https://github.com/srinathshankar","followers_url":"https://api.github.com/users/srinathshankar/followers","following_url":"https://api.github.com/users/srinathshankar/following{/other_user}","gists_url":"https://api.github.com/users/srinathshankar/gists{/gist_id}","starred_url":"https://api.github.com/users/srinathshankar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/srinathshankar/subscriptions","organizations_url":"https://api.github.com/users/srinathshankar/orgs","repos_url":"https://api.github.com/users/srinathshankar/repos","events_url":"https://api.github.com/users/srinathshankar/events{/privacy}","received_events_url":"https://api.github.com/users/srinathshankar/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2016-08-29T18:43:16Z","updated_at":"2016-09-01T03:02:00Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/apache/spark/pulls/14866","html_url":"https://github.com/apache/spark/pull/14866","diff_url":"https://github.com/apache/spark/pull/14866.diff","patch_url":"https://github.com/apache/spark/pull/14866.patch"},"body":"## What changes were proposed in this pull request?\r\n\r\nRequire the use of CROSS join syntax in SQL (and a new crossJoin\r\nDataFrame API) to specify explicit cartesian products between relations.\r\nBy cartesian product we mean a join between relations R and S where\r\nthere is no join condition involving columns from both R and S.\r\n\r\nIf a cartesian product is detected in the absence of an explicit CROSS\r\njoin, an error must be thrown. Turning on the\r\n\"spark.sql.crossJoin.enabled\" configuration flag will disable this check\r\nand allow cartesian products without an explicit CROSS join.\r\n\r\nThe new crossJoin DataFrame API must be used to specify explicit cross\r\njoins. The existing join(DataFrame) method will produce a INNER join\r\nthat will require a subsequent join condition.\r\nThat is df1.join(df2) is equivalent to select * from df1, df2.\r\n\r\n## How was this patch tested?\r\n\r\nAdded cross-join.sql to the SQLQueryTestSuite to test the check for cartesian products. Added a couple of tests to the DataFrameJoinSuite to test the crossJoin API. Modified various other test suites to explicitly specify a cross join where an INNER join or a comma-separated list was previously used.\r\n\r\n\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/apache/spark/issues/comments/243963031","html_url":"https://github.com/apache/spark/pull/14866#issuecomment-243963031","issue_url":"https://api.github.com/repos/apache/spark/issues/14866","id":243963031,"user":{"login":"SparkQA","id":8108735,"avatar_url":"https://avatars.githubusercontent.com/u/8108735?v=3","gravatar_id":"","url":"https://api.github.com/users/SparkQA","html_url":"https://github.com/SparkQA","followers_url":"https://api.github.com/users/SparkQA/followers","following_url":"https://api.github.com/users/SparkQA/following{/other_user}","gists_url":"https://api.github.com/users/SparkQA/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkQA/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkQA/subscriptions","organizations_url":"https://api.github.com/users/SparkQA/orgs","repos_url":"https://api.github.com/users/SparkQA/repos","events_url":"https://api.github.com/users/SparkQA/events{/privacy}","received_events_url":"https://api.github.com/users/SparkQA/received_events","type":"User","site_admin":false},"created_at":"2016-09-01T03:02:00Z","updated_at":"2016-09-01T03:02:00Z","body":"**[Test build #3242 has finished](https://amplab.cs.berkeley.edu/jenkins/job/NewSparkPullRequestBuilder/3242/consoleFull)** for PR 14866 at commit [`d5113f3`](https://github.com/apache/spark/commit/d5113f33c012f58bb079474296fd6cef6f583b1f).\n * This patch **fails PySpark unit tests**.\n * This patch merges cleanly.\n * This patch adds no public classes."}}
{"actor":{"display_login":"SparkQA"}}