-
Notifications
You must be signed in to change notification settings - Fork 234
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
Spark's coalesce operation performs lazy evaluation from left to right and returns the first non null value . In case of comet, the expressions are evaluated in parallel and throw an error in case one of them fails due to an exception (Example : Divide by Zero , Arithmetic Overflow) .
Steps to reproduce
A simple select coalesce(100, 1/0) from tbl
should be able to reproduce the error . Comet will throw a divide by zero exception while spark returns 100
Expected behavior
Match Spark's behavior i.e lazy evaluation
Additional context
Idea is to convert coalesce into a case expression to lazily evaluate expressions from left to right and return first non NULL value .
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working