You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "lorentzenchr (via GitHub)" <gi...@apache.org> on 2023/11/03 06:46:25 UTC
Re: [I] [C++] Sorting dictionary array not implemented [arrow]
lorentzenchr commented on issue #29887:
URL: https://github.com/apache/arrow/issues/29887#issuecomment-1791955082
With pyarrow version 14
```python
import pyarrow as pa
dict_array = pa.DictionaryArray.from_arrays([2, 0, 2, 1, 0], ["c", "a", "b"])
dict_array.dictionary_decode() # ["b", "c", "b", "a", "c"]
dict_array.sort().dictionary_decode() # ["a", "b", "b", "c", "c"]
```
So it is just the alpha numerical sort order, not the order as given by the dictionary. I find that a bit unfortunate and don't find any discussion of it.
--
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: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org