[ 
https://issues.apache.org/jira/browse/ARROW-14999?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17578135#comment-17578135
 ] 

Will Jones commented on ARROW-14999:
------------------------------------

Here's the issue Joris was talking about: 
https://issues.apache.org/jira/browse/ARROW-11497

I encountered this issue again here: 
https://github.com/delta-io/delta-rs/pull/684#discussion_r941965834

My recent experiences have led me to believe that (1) we should not care about 
field names when comparing ListType and (2) we should enable 
{{use_compliant_nested_type}} by default in Parquet writers. I am unable to 
determine any real use case for a custom field name in a {{ListType}} (there's 
only 1 field, so no need for a name to disambiguate), and preserving them and 
considering them in equality comparisons is proving to be annoying.

Though if that's not acceptable, I think we should at least provide an an 
option in the {{equals}} method to ignore field names in Lists and Maps.

> [C++] List types with different field names are not equal
> ---------------------------------------------------------
>
>                 Key: ARROW-14999
>                 URL: https://issues.apache.org/jira/browse/ARROW-14999
>             Project: Apache Arrow
>          Issue Type: Improvement
>          Components: C++
>    Affects Versions: 6.0.0
>            Reporter: Will Jones
>            Priority: Major
>
> When comparing map types, the names of the fields are ignored. This was 
> introduced in ARROW-7173.
> However for list types, they are not ignored. For example,
> {code:python}
> In [6]: l1 = pa.list_(pa.field("val", pa.int64()))
> In [7]: l2 = pa.list_(pa.int64())
> In [8]: l1
> Out[8]: ListType(list<val: int64>)
> In [9]: l2
> Out[9]: ListType(list<item: int64>)
> In [10]: l1 == l2
> Out[10]: False
> {code}
> Should we make list type comparison ignore field names too?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to