How to Ensure Type-Safe Querying with Drizzle ORM in a Base Repository’s Primary Key Handling?
I’m building an abstract base repository class using Drizzle ORM for a PostgreSQL database. The repository is generic and works with any table extending PgTable, and the primary key is passed dynamically. Here’s the relevant part of my implementation: