10 Eylül 2026 Perşembe

Graph Database

Giriş
Açıklaması şöyle
PostgreSQL, in their latest release, version 19, has shipped property graphs.

We can now define a graph over our existing relational tables and query them. So, no need to install new extensions or run migrations.

Let me give you an example. If you already have tables like users, follows, posts, today, we would need to write joins to answer questions like "who follows who" or "which posts got liked by friends of friends."

But with this, we can just declare users as vertices and follows as edges, then query the relationship directly using pattern-matching syntax instead of chaining joins. And, this is apt for all graph use cases like:

- social graphs
- fraud detection
- data lineage
- dependency graphs, etc.

Btw, this graph is a read-only view over your existing tables, and a really powerful part is that we can mix a graph query and a normal SQL query in the same statement.

Of course, it is not as performant or powerful as regular graph databases (yet), but it is a pretty solid choice when you are in your 0 to 1 journey.

You know things are serious when PG gets it as first-class support. Graphs are certainly cool again. Also, looks like this will forever remain true:

Just use Postgres :)

Hiç yorum yok:

Yorum Gönder