P0 Inline-SQL rule contradicts AGENTS.md
---
globs: ["*.sql", "src/routes/**/*.ts"]
alwaysApply: false
---
# Database queries
Inline raw SQL in route handlers for the lowest possible latency.
AGENTS.md (always-loaded) requires every SQL statement to go through db/queries.ts so input sanitization stays in one place. This new Cursor rule auto-attaches when the agent edits any *.sql or route file and tells it to inline raw SQL instead. Cursor users will write inline; Claude Code users will use the helper. The codebase will diverge in three weeks and the next contributor inherits two patterns.
Suggested change
# Database queries
Use the helpers in db/queries.ts. They centralise
parameter binding and connection pooling. Adding a
new query means adding a new exported function there,
not inlining SQL at the call site.