Revanth14 opened a new issue, #2419:
URL: https://github.com/apache/iceberg-go/issues/2419

   ### Feature Request / Improvement
   
   ## Problem
   `iceberg.LessThan(ref, math.NaN())`, `EqualTo`, `IsIn` and the other literal 
predicates accept a NaN literal and bind it. Java rejects one when the 
expression is built (`Literals.from`: "Cannot create expression literal from 
NaN"; `Expressions`: "use isNaN or notNaN instead"). With a NaN literal the 
results don't line up: the Arrow row filter returns no rows for `x = NaN` but 
matches NaN rows for `x IN (5, NaN)`, because `is_in` uses a hash set that 
treats NaN as equal to NaN, and `ExpressionEvaluator` agrees with neither for 
`=`, the ordering comparisons or `In`.
   
   ## Proposal
   Return an error for a NaN float32 or float64 literal from the predicate 
constructors or at bind time, pointing callers to `IsNaN` / `NotNaN`, as Java 
does. This is a breaking change for callers that build such predicates today, 
so it needs a `releases.md` compatibility note.
   
   ## Context
   Found while testing #2359.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to