You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@phoenix.apache.org by Susheel Kumar Gadalay <sk...@gmail.com> on 2018/06/07 06:35:22 UTC

SQL with join are running slow

Hi,

We have observed the SQL statements with table inner join are running very
slow.

From the explain plan we have noticed the first table filtered data is sent
to client and the subsequent table joins are run from client each joined
table data. Is it the way Phoenix execute SQL join statements?

Thanks
Susheel Kumar

Re: SQL with join are running slow

Posted by Josh Elser <el...@apache.org>.
That sounds like the implementation of a HashJoin. You would want to 
make sure your smaller relation is serialized for this HashJoin, not the 
larger one.

Phoenix also supports a sort-merge join which may be more better 
performing when you read a large percentage of data for both relations.

On 6/7/18 2:35 AM, Susheel Kumar Gadalay wrote:
> 
> 
> Hi,
> 
> We have observed the SQL statements with table inner join are running 
> very slow.
> 
>  From the explain plan we have noticed the first table filtered data is 
> sent to client and the subsequent table joins are run from client each 
> joined table data. Is it the way Phoenix execute SQL join statements?
> 
> Thanks
> Susheel Kumar