zhuqi-lucas commented on code in PR #27251:
URL: https://github.com/apache/datafusion/pull/27251#discussion_r4509720137
##########
datafusion/expr-common/src/type_coercion/binary.rs:
##########
@@ -1018,7 +1019,8 @@ fn comparison_coercion_inner<F>(
where
F: Fn(&DataType, &DataType) -> Option<DataType> + Copy,
{
- if lhs_type.equals_datatype(rhs_type) {
+ if lhs_type.equals_datatype(rhs_type) &&
struct_field_names_match(lhs_type, rhs_type)
Review Comment:
Not blocking: `array_coercion` (only used by `@>`/`<@`) still has an
unguarded `equals_datatype` fast path, so `List<Struct>` types differing only
in field names can still slip through there. Could be a small follow-up.
--
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]