Skip to content
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

[CALCITE-6549] Add LOG1P function (enabled in Spark library) #3934

Closed
wants to merge 1 commit into from

Conversation

caicancai
Copy link
Member

@caicancai caicancai commented Aug 27, 2024

Copy link

@caicancai
Copy link
Member Author

@NobiGo PTAL, thanks

@@ -4292,18 +4294,27 @@ private static List<Expression> args(RexCall call,
operand0 = operands.left;
operand1 = operands.right;
boolean nonPositiveIsNull = library == SqlLibrary.MYSQL ? true : false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should pass the library as the Parameter. Then the code logic will be clear. WDYT?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should refactor the code in another issue. The current code here has poor extensibilit.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I have to admit this. https://issues.apache.org/jira/browse/CALCITE-6550 is already working on this. I'll close it first.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@NobiGo Could you please post your opinion at https://issues.apache.org/jira/browse/CALCITE-6550? I think it is a very complicated issue.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you should pass in a library at run time. The runtime should not be worrying about high-level concepts like llibrary.

@caicancai caicancai closed this Aug 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants