Row-scoped data helpers
View as MarkdownUse scopedRows() as the ordinary data boundary after a route authenticates and
authorizes its caller. Choose the leaf that matches the operation:
- Scoped CRUD and bounded reads
covers
scopedRows(), create/update/delete,findMany(),page(), and cursor-backed scans. - Lookups and counts covers disjoint lookup modes, scalar counts, and grouped counts.
- Generated query resolvers covers the bridge from parsed generated HTTP queries to Drizzle-shaped helper inputs.
- Table row-security guards
covers
ownedRows(), trusted insert/patch preparation,serverValues, synchronous transactions, and raw/custom Drizzle responsibilities.
These helpers enforce row visibility only at the documented data boundary. Custom routes still choose and check their ability and data authority before touching rows.