[ 
https://issues.apache.org/jira/browse/HIVE-13019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15147807#comment-15147807
 ] 

Ruslan Dautkhanov commented on HIVE-13019:
------------------------------------------

Thank you Gopal. Oracle has "RELY NOVALIDATE" option for constraints.. would it 
be easier for Hive to start with something like that for PK/FK constraints? So 
CBO has more information for optimizations. It does not have to actually check 
if that constraint is relationship is actually true; it can just "rely" on that 
constraint.. Is this already plan for Hive 2.0? Thanks again.

> Optimizer COLLECT_LIST/COLLECT_SET 
> -----------------------------------
>
>                 Key: HIVE-13019
>                 URL: https://issues.apache.org/jira/browse/HIVE-13019
>             Project: Hive
>          Issue Type: Improvement
>          Components: CBO, Logical Optimizer
>            Reporter: Dustin Cote
>            Priority: Minor
>
> Currently when using a COLLECT_SET/COLLECT_LIST that involves data from a 
> single table, the aggregation is done after any JOIN operation that is 
> present in the query.  For example:
> {code}
> insert into table nested_customers_orders
> select c.*, collect_list(named_struct("oid", o.oid, "order_date": o.date...))
> from customers c inner join orders o on (c.cid = o.oid)
> group by o.oid, o.date,...
> {code}
> If we can tell the optimizer to perform the COLLECT_LIST first (where 
> possible) we can see some performance gains in this pattern of query.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to