implemented UNION (and a few other query operators)#184
implemented UNION (and a few other query operators)#184
Conversation
| FN_MIN_MAX(41), | ||
|
|
||
| SEQ_AGGR(48), | ||
| SORT(47), |
There was a problem hiding this comment.
Swap SEQ_AGGR and SORT to maintain ascending order?
|
|
||
| if (!theRCB.reachedLimit()) { | ||
| reqCopy.setMaxReadKB(origRequest.getMaxReadKB() - | ||
| theRCB.getReadKB()); |
There was a problem hiding this comment.
The maxReadKB of QueryRequest must be >=0. If origRequest.maxReadKB is not specified, it defaults to 0, then origRequest.getMaxReadKB() - theRCB.getReadKB() is negative and results in an IllegalArgumentException.
public QueryRequest setMaxReadKB(int maxReadKB) {
if (maxReadKB < 0) {
throw new IllegalArgumentException("maxReadKB must be >= 0");
}
this.maxReadKB = maxReadKB;
return this;
}
There was a problem hiding this comment.
Good point! To simplify things, I have modified the UnionIter so that when it gets done with the current branch it suspends the query instead of moving to the next branch (and thus sending another remote request).
There was a problem hiding this comment.
The Javadoc for the parameters proxyStatement, namespace, and tableName should be updated accordingly.
jinzha
left a comment
There was a problem hiding this comment.
The existing changes look good to me. Support for UNION across stores will be handled in a separate PR.
No description provided.