frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Ask HN: Any good tools to pgdump multi tenant database?

3•polishdude20•1y ago
Just joined a new company and they run a multi tenant database in postgres where each tenant is distinguished by their account ID. I'd like to be able to dump the data of a single account to my local instance to assist in debugging.

Problem is, many of the entities do not include an account ID. For example, a user can have an account ID but a user post will not but it will be tied to a user ID.

Also foreign keys aren't really implemented fully.

Are there any tools or techniques that could help make this process easier to do?

Comments

tudorg•1y ago
You can try with data subsetting tools, a few that I know are: greenmask, jailer, tonic condenser, and I think there are more. They are not exactly for your use case, but might help you a bit. The problem is most of these tools can walk foreign keys, but only in one directions.

Also, since you said FK are not fully implemented, then there just won't be enough information for them to work with. So you can either work on fixing the foreign keys or have more complex scripts.

polishdude20•1y ago
Thanks for the suggestions!

Yeah due to the unavailability of FK's, I'd have to somehow map certain ID columns to the tables they're for, accounting for slight naming convention differences.

woyten•1y ago
In case you don’t have FKs you could specify virtual foreign keys in Greenmask.

Check out docs for details

https://docs.greenmask.io/latest/database_subset/#virtual-re...

abhisek•1y ago
This is poor design. Multi-tenant data model design must have a tenant or segment ID for every tenant segmented tables. While it may not be a problem initially but as the business grows, you may need to move tenant data to separate DBs or even different regions based on compliance requirements. IMHO it is a good idea to run DB migrations and have a tenant ID populated in all tenant segmented tables
polishdude20•1y ago
Oh yes I agree with you. It may become a big push to convince my org to do that

Rust Beautifier: Beautiful, Fun and Opinionated Rust, the DHH Way

https://rust-beautifier.vercel.app
1•meerita•11s ago•0 comments

Upcoming election could produce modern Germany's first far-right state governor

https://apnews.com/article/germany-saxony-anhalt-election-far-right-afd-3162fbdd71e6f745eeb239e29...
1•geox•3m ago•0 comments

Rust Function Overloading – Call for Experimentation

https://blog.rust-lang.org/inside-rust/2026/08/19/overloading-experiment/
1•vinhnx•11m ago•0 comments

But where does taste come from?

https://dustycloud.org/blog/but-where-does-taste-come-from/
1•vinhnx•11m ago•0 comments

Cadence – a floating lyrics overlay for Spotify and YouTube Music

https://github.com/MowkE/cadence
1•Eclipzey•12m ago•0 comments

Gregg Shorthand

https://en.wikipedia.org/wiki/Gregg_shorthand
1•jaredwiener•17m ago•0 comments

OpenClaw 2.0

https://docs.openclaw.ai/releases/2026.8.1
1•guyinblackshirt•20m ago•0 comments

AI isn't sentient – the real danger lies in how easily we anthropomorphize it

https://theconversation.com/ai-isnt-close-to-becoming-sentient-the-real-danger-lies-in-how-easily...
1•Osiris30•21m ago•1 comments

Design Considerations for an Anthropophilic Computer (1979)

https://web.stanford.edu/dept/SUL/sites/mac/primary/docs/bom/anthrophilic.html
1•throw310822•29m ago•0 comments

ElephpantDB: A pure PHP SQL database

https://github.com/antonmedv/elephpantdb
1•medv•29m ago•0 comments

Protecting Postgres from everything that isn't Postgres

https://clickhouse.com/blog/protect-postgres-from-supporting-processes
1•saisrirampur•39m ago•0 comments

Anna's Archive Lost Several Domains

https://goodereader.com/blog/ebook-and-audiobook-piracy-news/annas-archive-lost-several-domains
1•kozmonaut•39m ago•0 comments

Building a Flight Controller in Rust

https://www.staszewski.xyz/blog/building-a-flight-controller-in-rust/
1•kamilstaszewski•45m ago•0 comments

The Open Air European Museum

https://www.theprincetontory.com/is-europe-an-open-air-museum/
1•satvikpendem•46m ago•0 comments

We run five Claude Code sessions at once

https://draper.chat/dev/the-ultimate-claude-code-parallelisation-guide-2026
1•tomchill•51m ago•0 comments

Second Wave Solarpunk

https://planetsandmonsters.blogspot.com/2026/08/second-wave-solarpunk.html
1•rdmuser•54m ago•0 comments

Vim Classic debuts with its first release as a Vim fork without AI assistance

https://www.neowin.net/news/vim-classic-debuts-with-its-first-release-as-a-vim-fork-without-ai-as...
1•pir8life4me•54m ago•1 comments

Sivers in Bangalore

https://sive.rs/met/at-15
1•nreece•58m ago•0 comments

Kansas town drops charges against teacher arrested for clapping

https://www.tomshardware.com/tech-industry/data-centers/kansas-town-drops-charges-against-teacher...
3•rdmuser•59m ago•0 comments

Show HN: Tracking spec-driven development in the wild

https://sddobservatory.com/
1•emilesilvis•1h ago•0 comments

PlayStation wants to prove in court that you don't own your digital games

https://www.polygon.com/sony-digital-games-lawsuit-california/
3•Markoff•1h ago•0 comments

I built a multiplayer version of the 4,500-year-old Royal Game of Ur

https://royalgameofur.app
2•potentdream•1h ago•0 comments

Roget's Thesaurus

https://artflsrv04.uchicago.edu/roget-thesaurus/
1•gregsadetsky•1h ago•0 comments

Faster than real-time video generation with #1 quality model

https://fal.ai/tools/minimax-h3-max
1•treesciencebot•1h ago•0 comments

Samsung's SmartThings API Terminates Free Access

https://hackaday.com/2026/07/28/samsungs-smartthings-api-terminates-free-access/
4•ryan_j_naughton•1h ago•0 comments

Any Recommended Alternatives to Google Maps and Apple Maps?

2•derbOac•1h ago•0 comments

Ask HN: How do you feel about AI generated documentation?

3•LelouBil•1h ago•1 comments

Rootless Docker and Its Hidden Security Trade-Offs

https://www.kenmuse.com/blog/rootless-docker-and-its-hidden-security-trade-offs/
2•zdw•1h ago•1 comments

Open Home Foundation

https://www.openhomefoundation.org/
2•LelouBil•1h ago•0 comments

Care for a Little More AI?

https://proofsandprompts.com/2026/08/30/care-for-a-little-more-ai/
1•Shuddown•1h ago•0 comments