frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

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

3•polishdude20•12mo 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•12mo 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•12mo 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•11mo 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•12mo 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•12mo ago
Oh yes I agree with you. It may become a big push to convince my org to do that

Foxconn confirms cyberattack after Nitrogen claims Apple, Nvidia data theft

https://www.theregister.com/cyber-crime/2026/05/12/foxconn-confirms-cyberattack-after-nitrogen-cl...
1•y1n0•55s ago•0 comments

When "idle" isn't idle: how a Linux kernel optimization became a QUIC bug

https://blog.cloudflare.com/quic-death-spiral-fix/
1•sbulaev•2m ago•0 comments

Scaling MCP adoption: Our ref architecture – simpler,safer&cheaper deployments

https://blog.cloudflare.com/enterprise-mcp/
1•Daviey•2m ago•0 comments

What the Heck Is Reflection?

https://www.murathepeyiler.com/what-the-heck-is-reflection/
1•HeliumHydride•2m ago•0 comments

Tesla moves Basic Autopilot features to paid FSD where available

https://electrek.co/2026/05/12/tesla-removes-basic-autopilot-netherlands-fsd-only/
1•y1n0•4m ago•0 comments

Mini Shai-Hulud Is Back: NPM Worm Hits over 160 Packages, Including Mistral

https://www.aikido.dev/blog/mini-shai-hulud-is-back-tanstack-compromised
1•cebert•4m ago•1 comments

The Silence That Meets the Rape of Palestinians

https://www.nytimes.com/2026/05/11/opinion/israel-palestinians-sexual-violence.html
2•Zaheer•6m ago•0 comments

Anthropic in Talks to Raise Funding at a $950B Valuation

https://www.nytimes.com/2026/05/12/technology/anthropic-funding-950-billion-valuation.html
2•y1n0•8m ago•0 comments

Mythos for Offensive Security: XBOW's Evaluation

https://xbow.com/blog/mythos-offensive-security-xbow-evaluation
1•tedsanders•10m ago•0 comments

Show HN: Display.dev, agent-native way to publish HTML or MD behind company auth

https://display.dev/
1•CarlRannaberg•12m ago•0 comments

World Record Solver for Minimum Line Cover of Prime Points Cuts Time to 22

https://prime-line-cover.vercel.app/?article
1•birdculture•14m ago•0 comments

Fluxspeak – make people sound human while reading

https://github.com/skorotkiewicz/freeflow/tree/main/fluxspeak
1•modinfo•17m ago•0 comments

Show HN: Rs-pug – A scriptable terminal music player written in Rust with Lua

https://github.com/JustRoccat/rs-pug
1•coldbrxthe•18m ago•0 comments

AI load breaks GitHub – why not other vendors?

https://blog.pragmaticengineer.com/the-pulse-ai-load-breaks-github/
3•esafak•21m ago•1 comments

Lukashenko Says Belarus Is Preparing for War, Plans to "Mobilize Units"

https://united24media.com/world/lukashenko-says-belarus-is-preparing-for-war-plans-to-mobilize-un...
2•arpadav•29m ago•0 comments

Android 17 will soon tell you whether your OS is legit

https://www.androidauthority.com/android-17-os-verification-3665868/
2•gumby271•31m ago•0 comments

The Cost of Doing Business: How SF's Tax Structure Constrains Economic Growth [pdf]

https://www.bayareaeconomy.org/files/pdf/CostofDoingBusiness_TaxStudy_May2026.pdf
2•littlexsparkee•32m ago•1 comments

In the Vacuum of AI Legislation, Libraries Have the Playbook

https://www.techdirt.com/2026/05/11/in-the-vacuum-of-ai-legislation-libraries-have-the-playbook/
2•hn_acker•35m ago•0 comments

Kraftwerk's radical 1976 track

https://www.bbc.com/culture/article/20260511-kraftwerks-radical-1976-track-radioactivity-became-a...
11•tcp_handshaker•35m ago•0 comments

Clusters become personal (like PCs did)

https://aranya.tech/blog/arrival-of-the-personal-cluster
2•druid•36m ago•0 comments

Tell NYT, Atlantic, USA Today to Keep Wayback Machine

https://www.savethearchive.com/newsleaders/
2•doener•37m ago•1 comments

Musk said control of OpenAI should go to his children, Sam Altman tells jury

https://www.bbc.com/news/articles/czj2k2exdzlo
2•tcp_handshaker•37m ago•0 comments

A Remarkably Luminous Galaxy at Zspec = 14.44 Confirmed with JWST

https://arxiv.org/abs/2505.11263
2•tcp_handshaker•39m ago•1 comments

Scientists Confirm 'Brain-Eating Amoeba' Is Widespread Yellowstone Grand Teton

https://cowboystatedaily.com/2026/05/12/scientists-confirm-brain-eating-amoeba-is-widespread-in-y...
3•Bender•40m ago•0 comments

What We Think About When We Think About Benchmarking

https://www.paradedb.com/blog/what-we-think-about-when-we-think-about-benchmarking
1•jamesgresql•41m ago•1 comments

FDA chief resigns after Trump admin forced approval of fruity e-cigs

https://arstechnica.com/health/2026/05/fda-chief-resigns-after-trump-admin-forced-approval-of-fru...
6•Bender•41m ago•0 comments

The newest AI boom pitch: Host a mini data center at your home

https://arstechnica.com/ai/2026/05/the-newest-ai-boom-pitch-host-a-mini-data-center-at-your-home/
2•Bender•42m ago•0 comments

Show HN: Clodcapture – save and resume Claude.ai chats across sessions

https://chromewebstore.google.com/detail/clodcapture/mhapejnhlmepeinjmlppoopcoicmgojb
1•leo_agent•44m ago•1 comments

Cherry Kearton: The eccentric influence on a young Sir David Attenborough

https://www.bbc.com/future/article/20260507-cherry-kearton-the-eccentric-influence-on-a-young-sir...
1•breve•47m ago•0 comments

Two more public disclosures, it will never stop

https://deadeclipse666.blogspot.com/2026/05/two-more-public-disclosures-it-will.html
1•Animux•47m ago•0 comments