Skip to content

Conversation

chenkovsky
Copy link
Contributor

Which issue does this PR close?

Rationale for this change

NaN != NaN

What changes are included in this PR?

Use arrow is_eq to test equality

Are these changes tested?

UT

Are there any user-facing changes?

No

@github-actions github-actions bot added sqllogictest SQL Logic Tests (.slt) physical-plan Changes to the physical-plan crate labels Jun 5, 2025
@chenkovsky chenkovsky marked this pull request as ready for review June 5, 2025 05:45
Copy link
Member

@andygrove andygrove left a comment

Choose a reason for hiding this comment

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

Thanks @chenkovsky!

}

*equal_to_result = self.group_values[lhs_row] == array.value(rhs_row);
*equal_to_result = self.group_values[lhs_row].is_eq(array.value(rhs_row));
Copy link
Member

Choose a reason for hiding this comment

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

The implementation of is_eq for floating point is self.to_bits() == rhs.to_bits()

@andygrove andygrove merged commit ab8cd8c into apache:main Jun 5, 2025
27 checks passed
kosiew pushed a commit to kosiew/datafusion that referenced this pull request Jun 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
physical-plan Changes to the physical-plan crate sqllogictest SQL Logic Tests (.slt)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Inconsistency with count distinct on NaN values
2 participants