Hacker News new | ask | show | jobs
by trinovantes 992 days ago
drizzle-orm is another good JS sql query builder

I'm able to write raw sql queries with the `sql` template literal function

https://orm.drizzle.team/docs/sql

3 comments

there's also https://kysely.dev/

but personally i handwrite my queries with https://github.com/porsager/postgres for flexibility and performance

most orms use node-pg lib which has shit performance.

I'm hand-writing stuff right now for Deno with MariaDB. Is there a "default" or "native" Postgres client, and what makes Porsager better if so?
There's a core client interface here:

- https://www.postgresql.org/docs/current/client-interfaces.ht...

On what makes it postgres.js faster, from author himself:

> it seems Postgres.js is actually faster than, not only pg, but of any driver out-there

- https://github.com/porsager/postgres/discussions/627

- https://porsager.github.io/imdbench/sql.html

Thanks for the reply!
+1 for Drizzle. I was really drawn to Prisma because it seemed elegant, but the problems surfaced by this blog post are really concerning.
Looks cool, thanks for sharing