[BUG] Filtering on built-in columns (createdAt, updatedAt) silently returns zero rows

Aperta
#5,920 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

  • #5972 di @tusharmotwani1718 — chiusa senza merge
  • #6114 di @serhiizghama — chiusa senza merge

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Ferma
Stack tecnologico
typescript
Ambito
api, database

Direzione di ricerca

Start with the v1 tables rows endpoint and its filter handling, then compare built-in-column filtering with the sort builder behavior described in the issue. Reproduce the createdAt range query and verify that filters on createdAt, updatedAt, and id return matching rows rather than an empty result.

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

Descrizione

bug

Describe the bug

The docs state that createdAt, updatedAt, and id are built-in columns that "you can still filter and sort on". Sorting on these works. Filtering on them does not. Any filter referencing a built-in column silently matches nothing and returns an empty result set.

To Reproduce

Via the v1 API:

GET /api/v1/tables/{tableId}/rows?workspaceId={wsId}&filter={"createdAt":{"$gte":"2026-07-24T03:00:00.000Z","$lte":"2026-07-25T02:59:59.999Z"}}

With a string value, returns 400 Bad Request:

{
  "error": "Range operator on column \"createdAt\" (number) requires a number, got string"
}

With a numeric value (Unix timestamp)

{ "rows": [], "rowCount": 0, "totalCount": 0 }

Passes validation, but returns empty results. No error, no warning, just zero rows regardless of how many rows match the range.

Expected behavior

Filters on createdAt / updatedAt / id compare against the top-level row columns (user_table_rows.createdAt, etc.) and return matching rows, mirroring the behavior the sort builder already provides.

Additional context

I think I can open a PR to solve this, if this intend to work the way I've described it.

Lingua principale
TypeScript
Stelle
29.8k
Fork
3.9k
Merge medio
1h 44m
PR unite (30g)
841

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di simstudioai/sim

Tutte le issue di simstudioai/sim

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.