apache / apache/datafusion

Sort options for DataType::Dictionary is incorrect

Aperta
#4,649 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
enhancement
Lingua principale
Rust
Stelle
9.3k
Fork
2.4k
Merge medio
3g 11h
PR unite (30g)
360

Descrizione

**Is your feature request related to a problem or challenge? Please describe what you are trying to do.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
(This section helps Arrow developers understand the context and *why* for this feature, in addition to the *what*)

Looks like when the DataType is `Dictionary`, it always reset the Nulls First settings and ignore the sort option from the query engine. This will generate wrong sort result. I will add a UT to reproduce the issue.

https://github.com/apache/arrow-rs/blob/a0a5880665b1836890f6843b6b8772d81c463351/arrow-ord/src/sort.rs#L316-L332

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia leggendo arrow-ord/src/sort.rs intorno alle righe 316-332 e riproduci il caso di ordinamento di Dictionary descritto nell’issue. Aggiungi il test unitario promesso che copra le impostazioni nulls-first, quindi verifica che l’ordinamento rispetti l’opzione di ordinamento del motore di query e produca il risultato corretto.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
rust
Ambito
data-engineering
Tipo di issue
Bug
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
42/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.