Null-aware hash join loses `NOT IN` semantics when converted to `SymmetricHashJoinExec`
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
- #27226 de @shehabgamin — fechado sem integrar
Avaliação
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Facilidade para iniciantes
- 35/100
Direção de pesquisa
Start by reading JoinSelection and SymmetricHashJoinExec in DataFusion’s Rust source, then trace the null_aware handling for HashJoinExec. Add or use a regression test that builds the null-aware LeftAnti join described in the issue and runs JoinSelection. Done means optimization keeps it as HashJoinExec; an open linked pull request already addresses this issue.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Describe the bug
JoinSelection turns a HashJoinExec into a SymmetricHashJoinExec when both inputs are unbounded. It does this without checking null_aware. SymmetricHashJoinExec has no null-aware mode, so the flag is dropped and a NOT IN join becomes a plain anti join. A NULL in the subquery, or a NULL outer value, no longer gives SQL NOT IN semantics, so the query can return rows it should not.
To Reproduce
Build a null-aware LeftAnti HashJoinExec over two unbounded inputs and run JoinSelection on it. The result is a SymmetricHashJoinExec, and the null-aware behavior is gone.
let join = HashJoinExec::try_new(
left, right, on, None, &JoinType::LeftAnti, None,
PartitionMode::CollectLeft, NullEquality::NullEqualsNothing,
true, // null_aware
)?;
let optimized = JoinSelection::new().optimize(Arc::new(join), &ConfigOptions::new())?;
// optimized is a SymmetricHashJoinExec
Expected behavior
A null-aware join stays a HashJoinExec, the only join that implements null-aware semantics for this case.
Additional context
No response
Willingness to contribute
I plan to contribute a fix for this bug independently
- Linguagem predominante
- Rust
- Estrelas
- 9.6k
- Forks
- 2.6k
- Merge médio
- 3d 4h
- PRs com merge (30d)
- 345
Preparar o ambiente
Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de apache/datafusion
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
apache/datafusion#27315 · 2 comentários ·
Mantenedores costumam responder em até 1 dia
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
apache/datafusion#27094 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Substrait consumer doesn't recognise `shift_left` / `shift_right` from functions_arithmetic.yamlTalvez já em andamento @jonasHanhan assumiu há 9 dias. Abertabug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
apache/datafusion#27059 ·
Mantenedores costumam responder em até 1 dia
-
`ProjectionExprs::project_statistics` computes approximate `Statistics::total_byte_size` ignoring column statsTalvez já em andamento @joseph-isaacs assumiu há 10 dias. Abertabug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
apache/datafusion#27050 ·
Mantenedores costumam responder em até 1 dia
-
physical-plan: decoding an Unnest or Explain node with an unset field panicsTalvez já em andamento @geoHeil assumiu há 9 dias. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
apache/datafusion#26999 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
Todas as issues de apache/datafusion
Issues semelhantes
-
P3
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
HerringtonDarkholme/hd-lang#1770 ·
Mantenedores costumam responder em até 1 dia
-
needs triage
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 85/100
pbakaus/impeccable#1436 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 82/100
jonathanong/no-mistakes#3332 ·
Mantenedores costumam responder em até 1 dia
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
swc-project/swc-next-issues#310 ·
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
swc-project/swc-ai-issues#653 ·