I want to use this as a chance to bring attention to a GitHub issue that I think would help reduce friction for Neon: https://github.com/neondatabase/neon/issues/4989. Having run a local dev environment connected to Neon and tests connected to Neon got in our way of adoption. We'd prefer to develop and run tests against a regular Postgres localhost database. To the PMs of Neon, put yourself in the shoes of a new... - Source: Hacker News / 18 days ago
I'd push you to consider using postgres, slonik or similar for database queries. With these libraries, you just write SQL, but they perform input sanitization for you. So you can safely write:. Source: 5 months ago
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. - Source: Hacker News / 7 months ago
When viewed as a DSL for set theory, views, CTEs, set-returning functions, et al are indeed proper first-class query abstractions. When viewed through the lens of general purpose imperative or functional programming languages, it's easy to see how it can be seen as falling short. I'll admit much of the tooling and driver APIs leave a lot to be desired. Some tools do make good efforts though such as nested... - Source: Hacker News / 8 months ago
Demonstrate how easily and accidentally one can make an SQL injection with these: https://github.com/porsager/postgres. - Source: Hacker News / 10 months ago
In NodeJS land this library is pretty close to this: https://github.com/porsager/postgres. - Source: Hacker News / 11 months ago
They've looked at Postgres.js (https://github.com/porsager/postgres) before — wouldn't mind if they enabled those other cases in the same way. - Source: Hacker News / about 1 year ago
I'm using Supabase as my database, with RLS turned on. I query the DB from a Node backend using the postgres.js client (it could be any other JS client really). As such I'm connecting direct with the default postgres user and I issue raw SQL queries. Source: about 1 year ago
About a year ago I moved to raw SQL using Postgres.js. Honestly I thought it would be traumatic but it's been great so far. Source: over 1 year ago
Worse: Ecosystem Better: Seamless TypeScript support without having to deal with 3rd party packages or tsconfigs. A standard library modeled after Go's that is a WIP, but solid overall. Having browser APIs in the runtime is great, removes the mental context switch between browser/node. Formatter built in to the binary. YMMV, but I prefer the url imports and lack of package.json. I can't speak from a professional... - Source: Hacker News / over 1 year ago
Not sure about ORM, but Postgres.js[0] works on Deno. For testing, Deno includes a built-in test runner and assertions via the std[1]. [0] https://github.com/porsager/postgres [1] https://deno.land/manual/testing. - Source: Hacker News / almost 2 years ago
>Same deal with Postgres. `pg` would not compile at all. Knex also didn't work (this was an older project). You should take a look at Postgres.js [0] which supports Deno and TypeScript. Version 3.x was released recently and discussed in this HN thread [1]. [0] https://github.com/porsager/postgres. - Source: Hacker News / almost 2 years ago
I am using postgres.js in my webapp and wondering if I still need the M in MVC. Source: almost 2 years ago
Https://github.com/porsager/postgres More features, much bigger community involvement. Source: almost 2 years ago
Something to note about the benchmarks hosted on https://github.com/porsager/postgres, is that the author is benchmarking the latest version of postgres against old versions of libraries (e.g. Slonik v23.5.5, vs the current v27.1.1). Source: about 2 years ago
Hi everyone. Just released Postgres.js v3 today.https://github.com/porsager/postgres / npm install postgresA bit more than two years ago I released the first version of Postgres.js. A fully functional PostgreSQL driver for Node.js written as a learning experience out of curiosity and annoyance with the current options. It greatly outperformed the alternatives[1] using pipelining and prepared statements, while... Source: about 2 years ago
Thanks a lot! What a coincidence - and perfect timing since v3 supports .raw()[1] to receive results as arrays. I'd also be very curious to hear how replacing pg goes :) And also good job on Imba! I'm a really big fan of stripping syntax down to the bare essentials, and what you've done with Imba is really impressive! [1] https://github.com/porsager/postgres#raw. - Source: Hacker News / about 2 years ago
Hi everyone. Just released Postgres.js v3 today.https://github.com/porsager/postgres / npm install postgresA bit more than two years ago I released the first version of Postgres.js. A fully functional PostgreSQL driver for Node.js written as a learning experience out of curiosity and annoyance with the current options. It greatly outperformed the alternatives[1] using pipelining and prepared statements, while... Source: about 2 years ago
It greatly outperformed the alternatives[1] using pipelining and prepared statements, while providing a much better development experience safe from SQL injections. Since then I've been busy building things using it, now running in production, and although quite delayed I'm so happy to release a new major today with some really exciting new features: 1. Realtime subscribe to changes through Logical Replication [2]... - Source: Hacker News / about 2 years ago
I prefer the postgres module. 0 dependencies. Easy to use API. Wicked fast. Also really hard to fall victim to SQL injection attacks unless you actually put some extra effort into doing something foolish. https://github.com/porsager/postgres#readme. - Source: Hacker News / almost 3 years ago
Do you know an article comparing Postgres.js to other products?
Suggest a link to a post with product alternatives.
This is an informative page about Postgres.js. You can review and discuss the product here. The primary details have not been verified within the last quarter, and they might be outdated. If you think we are missing something, please use the means on this page to comment or suggest changes. All reviews and comments are highly encouranged and appreciated as they help everyone in the community to make an informed choice. Please always be kind and objective when evaluating a product and sharing your opinion.