Merge 'Add support for nullif scalar function' from Kim Seon Woo

### EXPLAIN nullif(1,2)
<img width="1339" alt="image" src="https://github.com/user-attachments/assets/08230797-914d-4922-b52c-5b2b2b4c2a12">

### Issue
https://github.com/penberg/limbo/issues/144

Closes #299
This commit is contained in:
Pekka Enberg
2024-08-20 20:47:35 +03:00
5 changed files with 107 additions and 5 deletions

View File

@@ -279,6 +279,18 @@ do_execsql_test max-null {
select max(null,null)
} {}
do_execsql_test nullif {
select nullif(1, 2)
} {1}
do_execsql_test nullif {
select nullif(1, 1)
} {}
do_execsql_test nullif {
select nullif('limbo', 'limbo')
} {}
do_execsql_test substr-3-args {
SELECT substr('limbo', 1, 3);
} {lim}