-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Vectorized][Feature] Support min_by/max_by function. #8623
Conversation
Expr aggExprParam = | ||
new SlotRef(inputDesc.getSlots().get(i + getGroupingExprs().size())); | ||
List<Expr> paramExprs = new ArrayList<>(); | ||
if (inputExpr.fn.functionName().equals("max_by")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a tricky workaround, won't merge to trunk code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Discussed with @HappenLee and @yiguolei , we should change the intermediateType to a list, in another PR, in current PR, we just keep the hard code way.
we can add docs for these new functions @zhannngchen |
Yes, I'll update the patch later today |
::testing::ValuesIn(std::vector<std::string> {"min_by", "max_by"})); | ||
} // namespace doris::vectorized | ||
|
||
int main(int argc, char** argv) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We changed unit test running mechanism, not every unit test has a main function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cleared
if (StringRef(Data::name()) == StringRef("min_by") || | ||
StringRef(Data::name()) == StringRef("max_by")) { | ||
if (!key_type_->is_comparable()) { | ||
LOG(FATAL) << fmt::format( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be an assertion?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
PR approved by anyone and no changes requested. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
PR approved by at least one committer and no changes requested. |
Support min_by/max_by on vectorized engine.
…he#8623) Support min_by/max_by on vectorized engine.
…he#8623) Support min_by/max_by on vectorized engine.
…he#8623) Support min_by/max_by on vectorized engine.
…he#8623) Support min_by/max_by on vectorized engine.
Proposed changes
Issue Number: open #7678
Problem Summary:
Support min_by/max_by on vectorized engine.
Checklist(Required)
Further comments