Interesting. Have you tried https://github.com/kysely-org/kysely ?
I know Prisma is an ORM and kysely is a "type-safe typescript SQL query builder" but I just wanted to know if you had the opportunity to try it and your opinion about it.
I'm searching for SQL typescript tooling for my next project.
I would recommend to use just good old database client and send your queries as text, nothing it's easier than that, every orm struggles when you want to do some relatively complex query, I struggled to do something like this with kysely `LEFT JOIN table2 ON (table1.id = tabl2.id AND table2.status = 1` was insane how complicated it was, sure you can pass raw sql, but what's the point of the orm then.
Have you tried Slonik (https://github.com/gajus/slonik)? It won't generate types from queries automatically, but it encourages writing SQL vs. a query builder and allows type annotations of queries with Zod. Query results are validated at runtime to ensure the queries are typed correctly.
I'm searching for SQL typescript tooling for my next project.