Skip to content

feat: Implement equality = and inequality <> support for BinaryView - #11004

Merged
alamb merged 2 commits into
apache:string-viewfrom
PsiACE:binary-view
Jun 20, 2024
Merged

feat: Implement equality = and inequality <> support for BinaryView#11004
alamb merged 2 commits into
apache:string-viewfrom
PsiACE:binary-view

Conversation

@PsiACE

Copy link
Copy Markdown
Member

Which issue does this PR close?

Closes#10996 .

Rationale for this change

What changes are included in this PR?

Are these changes tested?

Are there any user-facing changes?

Signed-off-by: Chojan Shang <psiace@apache.org>
@github-actionsgithub-actionsBot added logical-expr Logical plan and expressions sqllogictest SQL Logic Tests (.slt) labels Jun 19, 2024
Signed-off-by: Chojan Shang <psiace@apache.org>

@alambalamb left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you @PsiACE -- very nice

(Binary | Utf8, Binary) | (Binary, Utf8) => Some(Binary),
(LargeBinary | Binary | Utf8 | LargeUtf8, LargeBinary)
| (LargeBinary, Binary | Utf8 | LargeUtf8) => Some(LargeBinary),
(BinaryView, BinaryView) | (BinaryView, Binary) | (Binary, BinaryView) => {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🤔 I wonder if we should also handle LargeBinary as well

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

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

We also don't handle LargeUtf8. 👀

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Good call -- I filed #11023 to track

@alamb

Copy link
Copy Markdown
Contributor

Thanks again @PsiACE

@PsiACE
PsiACE deleted the binary-view branch June 20, 2024 11:57
alamb added a commit that referenced this pull request Jul 16, 2024
…velopment branch (#11402)
* Update `string-view` branch to arrow-rs main (#10966)
* Pin to arrow main
* Fix clippy with latest arrow
* Uncomment test that needs new arrow-rs to work
* Update datafusion-cli Cargo.lock
* Update Cargo.lock
* tapelo
* feat: Implement equality = and inequality <> support for StringView (#10985)
* feat: Implement equality = and inequality <> support for StringView
* chore: Add tests for the StringView
* chore
* chore: Update tests for NULL
* fix: Used build_array_string!
* chore: Update string_coercion function to handle Utf8View type in binary.rs
* chore: add tests
* chore: ci
* Add more StringView comparison test coverage (#10997)
* Add more StringView comparison test coverage
* add reference
* Add another test showing casting on columns works correctly
* feat: Implement equality = and inequality <> support for BinaryView (#11004)
* feat: Implement equality = and inequality <> support for BinaryView
Signed-off-by: Chojan Shang <psiace@apache.org>
* chore: make fmt happy
Signed-off-by: Chojan Shang <psiace@apache.org>
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
* Implement support for LargeString and LargeBinary for StringView and BinaryView (#11034)
* implement large binary
* add tests for large string
* better comments for string coercion
* Improve filter predicates with `Utf8View` literals (#11043)
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Improve type coercion logic in TypeCoercionRewriter
* chore
* chore: Update test
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Remove unused import and update code formatting in unwrap_cast_in_comparison.rs
* Remove arrow-patch
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Alex Huang <huangweijun1001@gmail.com>
Co-authored-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Xiangpeng Hao <haoxiangpeng123@gmail.com>
xinlifoobar pushed a commit to xinlifoobar/datafusion that referenced this pull request Jul 17, 2024
…velopment branch (apache#11402)
* Update `string-view` branch to arrow-rs main (apache#10966)
* Pin to arrow main
* Fix clippy with latest arrow
* Uncomment test that needs new arrow-rs to work
* Update datafusion-cli Cargo.lock
* Update Cargo.lock
* tapelo
* feat: Implement equality = and inequality <> support for StringView (apache#10985)
* feat: Implement equality = and inequality <> support for StringView
* chore: Add tests for the StringView
* chore
* chore: Update tests for NULL
* fix: Used build_array_string!
* chore: Update string_coercion function to handle Utf8View type in binary.rs
* chore: add tests
* chore: ci
* Add more StringView comparison test coverage (apache#10997)
* Add more StringView comparison test coverage
* add reference
* Add another test showing casting on columns works correctly
* feat: Implement equality = and inequality <> support for BinaryView (apache#11004)
* feat: Implement equality = and inequality <> support for BinaryView
Signed-off-by: Chojan Shang <psiace@apache.org>
* chore: make fmt happy
Signed-off-by: Chojan Shang <psiace@apache.org>
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
* Implement support for LargeString and LargeBinary for StringView and BinaryView (apache#11034)
* implement large binary
* add tests for large string
* better comments for string coercion
* Improve filter predicates with `Utf8View` literals (apache#11043)
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Improve type coercion logic in TypeCoercionRewriter
* chore
* chore: Update test
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Remove unused import and update code formatting in unwrap_cast_in_comparison.rs
* Remove arrow-patch
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Alex Huang <huangweijun1001@gmail.com>
Co-authored-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Xiangpeng Hao <haoxiangpeng123@gmail.com>
xinlifoobar pushed a commit to xinlifoobar/datafusion that referenced this pull request Jul 18, 2024
…velopment branch (apache#11402)
* Update `string-view` branch to arrow-rs main (apache#10966)
* Pin to arrow main
* Fix clippy with latest arrow
* Uncomment test that needs new arrow-rs to work
* Update datafusion-cli Cargo.lock
* Update Cargo.lock
* tapelo
* feat: Implement equality = and inequality <> support for StringView (apache#10985)
* feat: Implement equality = and inequality <> support for StringView
* chore: Add tests for the StringView
* chore
* chore: Update tests for NULL
* fix: Used build_array_string!
* chore: Update string_coercion function to handle Utf8View type in binary.rs
* chore: add tests
* chore: ci
* Add more StringView comparison test coverage (apache#10997)
* Add more StringView comparison test coverage
* add reference
* Add another test showing casting on columns works correctly
* feat: Implement equality = and inequality <> support for BinaryView (apache#11004)
* feat: Implement equality = and inequality <> support for BinaryView
Signed-off-by: Chojan Shang <psiace@apache.org>
* chore: make fmt happy
Signed-off-by: Chojan Shang <psiace@apache.org>
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
* Implement support for LargeString and LargeBinary for StringView and BinaryView (apache#11034)
* implement large binary
* add tests for large string
* better comments for string coercion
* Improve filter predicates with `Utf8View` literals (apache#11043)
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Improve type coercion logic in TypeCoercionRewriter
* chore
* chore: Update test
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Remove unused import and update code formatting in unwrap_cast_in_comparison.rs
* Remove arrow-patch
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Alex Huang <huangweijun1001@gmail.com>
Co-authored-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Xiangpeng Hao <haoxiangpeng123@gmail.com>
wiedld pushed a commit to influxdata/arrow-datafusion that referenced this pull request Jul 31, 2024
…velopment branch (apache#11402)
* Update `string-view` branch to arrow-rs main (apache#10966)
* Pin to arrow main
* Fix clippy with latest arrow
* Uncomment test that needs new arrow-rs to work
* Update datafusion-cli Cargo.lock
* Update Cargo.lock
* tapelo
* feat: Implement equality = and inequality <> support for StringView (apache#10985)
* feat: Implement equality = and inequality <> support for StringView
* chore: Add tests for the StringView
* chore
* chore: Update tests for NULL
* fix: Used build_array_string!
* chore: Update string_coercion function to handle Utf8View type in binary.rs
* chore: add tests
* chore: ci
* Add more StringView comparison test coverage (apache#10997)
* Add more StringView comparison test coverage
* add reference
* Add another test showing casting on columns works correctly
* feat: Implement equality = and inequality <> support for BinaryView (apache#11004)
* feat: Implement equality = and inequality <> support for BinaryView
Signed-off-by: Chojan Shang <psiace@apache.org>
* chore: make fmt happy
Signed-off-by: Chojan Shang <psiace@apache.org>
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
* Implement support for LargeString and LargeBinary for StringView and BinaryView (apache#11034)
* implement large binary
* add tests for large string
* better comments for string coercion
* Improve filter predicates with `Utf8View` literals (apache#11043)
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Improve type coercion logic in TypeCoercionRewriter
* chore
* chore: Update test
* refactor: Improve type coercion logic in TypeCoercionRewriter
* refactor: Remove unused import and update code formatting in unwrap_cast_in_comparison.rs
* Remove arrow-patch
---------
Signed-off-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Alex Huang <huangweijun1001@gmail.com>
Co-authored-by: Chojan Shang <psiace@apache.org>
Co-authored-by: Xiangpeng Hao <haoxiangpeng123@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

logical-exprLogical plan and expressionssqllogictestSQL Logic Tests (.slt)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@PsiACE@alamb