REST from your database catalog
    DocumentationCheat sheetQuestionsDownloadSource
    Questions
    • How do I...?
    Start here
    • Getting started
    • What a table becomes
    • Compared with PostgREST
    Setting up
    • Tables, columns and relations
    • Security and hooks
    • Writes and procedures
    • Prefer: return=representation
    • Node, Fastify, Express
    Reading
    • select
    • /{key}
    • relation(...)
    • order
    • limit, offset
    • relation.order, .limit
    • count
    • count(), sum(), avg()...
    • "name"
    Filtering
    • eq, neq
    • gt, gte, lt, lte
    • in
    • like, ilike
    • match, imatch
    • is
    • ov, cs, cd
    • not
    • relation.column
    • or, and
    Databases
    • Supported databases
    • Adding a database
    Reference
    • Cheat sheet
    • Errors
    Filtering

    Either-or

    Group terms in or=(...) to keep rows matching any of them.

    or=(status.eq.done,owner.name.eq.Linus)or=(a.eq.1,and(b.eq.2,c.eq.3))

    Each term is column.operator.value, with the same operators and relation paths as a filter. Inside an or, and(...) groups terms that must all hold, one level deep.

    An or combines with the request's other filters: they must all hold, and so must the or.

    Examples

    Done, or owned by Linus.
    /todos?select=name&or=(status.eq.done,owner.name.eq.Linus)

    Asking the database...

    Done, or both pinned and longer than three hours.
    /todos?select=name&or=(status.eq.done,and(pinned.is.true,estimate.gt.3))

    Asking the database...

    See alsoTurn a filter around
    PreviousFilter through a relationNext Supported databases
    restloom - a REST API generated from your database catalog
    DocumentationDownloadSource