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

feat(sql): add nullif(long,long) SQL function #3188

Merged
merged 8 commits into from
Apr 20, 2023

Conversation

javier
Copy link
Contributor

@javier javier commented Apr 13, 2023

NullIf supports now also comparison between long numbers

…ments

nullif(int,int) was expecting a function and a constant integer, and would break in queries like `select nullif(now()::int, now()::int)`. Changed the function to accept functions as both arguments.
NullIf supports now also comparison between long numbers
@javier javier changed the title feat(sql) Added NullIfLong SQL function feat(sql): Added NullIfLong SQL function Apr 13, 2023
@bluestreak01 bluestreak01 changed the title feat(sql): Added NullIfLong SQL function feat(sql): add nullif(long,long) SQL function Apr 17, 2023
The former name, NullIfIFunctionFactory was not consistent with other functions. Clearer now, hopefully
Added extra tests for non-constant values for Int and Long types
@ideoma
Copy link
Collaborator

ideoma commented Apr 20, 2023

[PR Coverage check]

😍 pass : 22 / 22 (100.00%)

file detail

path covered line new line coverage
🔵 io/questdb/griffin/engine/functions/conditional/NullIfIntFunctionFactory.java 10 10 100.00%
🔵 io/questdb/griffin/engine/functions/conditional/NullIfLongFunctionFactory.java 12 12 100.00%

@bluestreak01 bluestreak01 merged commit 3b4a3cb into master Apr 20, 2023
17 checks passed
@bluestreak01 bluestreak01 deleted the jv/nullifLongfunction branch April 20, 2023 15:32
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.

None yet

4 participants