you could probably just say (1 = 1) in the on clause for the join.
select ... from T1 join T2 on (1 = 1);
On May 1, 2011, at 10:27 PM, Raghunath, Ranjith wrote:
Forgot to mention....the condition for the inner join should be the column set to 1 in the first table to be equal to the same column in the other table.
From: Raghunath, Ranjith <Ranjith.Raghunath1@usaa.com
To: 'email@example.com ' <firstname.lastname@example.org
Sent: Mon May 02 00:21:57 2011
Subject: Re: Cross join in Hive.
I haven't tested this out but plan to in 6 hours. Add an extra column and set it to 1 in both tables. Perform an inner join between the two tables.
From: Abhinov Agarwal <email@example.com
To: firstname.lastname@example.org <email@example.com
Sent: Sun May 01 22:50:34 2011
Subject: Cross join in Hive.
I need to take a cross join of a big table with itself, is it possible to do it using Hive ?
This would also do :
In fact the second one is what I want. I know cross join is not supported in Hive, any other way to obtain this.