Make filters and ordering follow PostgreSQL comparison semantics

Aberta
#38 0 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
35/100
Tipo de issue
Bug
Clareza
Claramente especificada
Status de atividade
Ativa
Stack de tecnologia
postgresql, rust
Domínio
backend, databases

Direção de pesquisa

Start by locating the engine’s filter comparison and ORDER BY code, then read how it represents PostgreSQL types, collations, enums, and NULL values. Add cases that compare engine results with PostgreSQL for each listed behavior, including NaN, empty NOT IN, and LIMIT ordering. Done means all acceptance criteria pass; the issue does not name specific files or tests.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

Problem

Some filters and ordering operations do not match PostgreSQL:

  • Types not modeled by the engine (including interval, inet, cidr, macaddr, timetz, and ranges) are compared as text.
  • citext, char(n), and text using nondeterministic collations are compared byte by byte.
  • Text range filters and ORDER BY use byte order even when the column’s collation sorts differently (for example, en_US).
  • Enum range filters and ORDER BY sort labels as text instead of following enum declaration order.
  • Float NaN never matches a range condition.
  • x NOT IN () omits rows where x is NULL, though PostgreSQL returns every row for an empty list.
  • With ORDER BY … LIMIT, rows with NULL sort values can be excluded from the limited window even when PostgreSQL would include them.

Expected behavior

Filters and ordering should produce results consistent with PostgreSQL for these types, collations, NULL values, and edge cases.

Acceptance criteria

  • Comparisons for the listed types match PostgreSQL semantics, or unsupported types are handled explicitly rather than silently compared as text.
  • Text comparison and ordering respect the column’s collation and type.
  • Enum comparisons and ordering respect declaration order.
  • NaN, empty NOT IN lists, and NULL ordering with LIMIT match PostgreSQL.
  • Tests compare engine results with PostgreSQL results for the cases above.
Linguagem predominante
Rust
Estrelas
129
Forks
7
Merge médio
1d 19h
PRs com merge (30d)
5

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de juspay/streamgres

Todas as issues de juspay/streamgres

Issues semelhantes

Mais issues de Rust

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.