Type-safe query builders sound great in theory, but it seems there are always edge cases that are not supported by the query builder.
For example, the issue asking for deferrable constraint support for Postgres in drizzle has been open for about a year: https://github.com/drizzle-team/drizzle-orm/issues/1429
In any non-trivial application, you are increasingly likely to run into something that your database supports but your query-builder does not. What will you do then?
It's sad, but unfortunately the most reliable approach seems to be to write raw SQL in a DAO package/library, then using integration tests (DAO + database) to confirm behavior.