Taewoo Kim has posted comments on this change.

Change subject: ASTERIXDB-1487: fix the wrong plan when we purning the 
selective branch.
......................................................................


Patch Set 12:

I discussed this with Wenhai. 

For a join such as A.x = B.y, we need to make sure that
1) The datasourcescan of A and B refers to the same dataset (A,B = the same 
dataset)
2) Operators after the join do not use any variables from one branch.
3) The fields X and Y should be the same field

I am not sure whether the current rule checks the condition 3) properly.

Wenhai also mentioned two issues:
#a. We have a SELECT condition besides to the above (e.g., A.x = B.y and A.z < 
100). In this case, We have a datasource scan, followed by a SELECT, then the 
join op. We can't prune the A branch since if we do so, A.z can't be checked. A 
solution could be moving A.z < 100 after the join operator and change it to B.z 
< 100. 

#b. For surrogate join case that utilizes a secondary inverted index-search, 
this rule always prune the inner branch (which does main job). How to let this 
recognize the inner branch is an issue.

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1119
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I1aef69a2278853fd9f8020da6639331b367ed5ad
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Wenhai Li <lwhaym...@yahoo.com>
Gerrit-Reviewer: Chen Li <che...@gmail.com>
Gerrit-Reviewer: Jenkins <jenk...@fulliautomatix.ics.uci.edu>
Gerrit-Reviewer: Jianfeng Jia <jianfeng....@gmail.com>
Gerrit-Reviewer: Taewoo Kim <wangs...@yahoo.com>
Gerrit-Reviewer: Till Westmann <ti...@apache.org>
Gerrit-Reviewer: Wenhai Li <lwhaym...@yahoo.com>
Gerrit-Reviewer: Yingyi Bu <buyin...@gmail.com>
Gerrit-Reviewer: Yingyi Bu <ying...@google.com>
Gerrit-HasComments: No

Reply via email to