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

The Atari 1200XL

https://www.goto10retro.com/p/inside-the-atari-1200xl
1•ibobev•24s ago•0 comments

Anthropic: Long-running Claude for scientific computing

https://www.anthropic.com/research/long-running-Claude
1•theorchid•1m ago•0 comments

Why Keynes Was Wrong

https://thecritic.co.uk/why-keynes-was-wrong/
1•RickJWagner•2m ago•0 comments

Ask HN: What's your favorite Emacs package?

1•blenderob•4m ago•0 comments

Can a geometric manifold solve AI hallucinations better than probability?

1•enitylabsindia•5m ago•0 comments

Markdown (2004)

http://www.aaronsw.com/weblog/001189
1•lr0•6m ago•0 comments

The Factor Behind Your Home Insurance Cost: Your Credit History

https://www.nytimes.com/interactive/2026/03/09/climate/home-insurance-credit-scores.html
1•therobots927•10m ago•1 comments

Show HN: Kadō, an open source habit tracker app for iOS

https://github.com/scastiel/kado
2•scastiel•11m ago•0 comments

Show HN: An elegant HN client with built-in translation

https://haiker.app/en
1•djyde•11m ago•1 comments

Tim Cook: Great for Apple Investors Not Great for America. Gift Article

https://www.nytimes.com/2026/04/23/opinion/apple-tim-cook-outsourcing-china.html
3•oldnetguy•11m ago•0 comments

Thinky Games

https://thinkygames.com/
1•agnishom•11m ago•0 comments

Permission Slip – Self-hostable approval layer for destructive OpenClaw actions

https://github.com/supersuit-tech/permission-slip
1•chiedo•11m ago•1 comments

Millions of Americans may now also be considered Canadian under new law

https://apnews.com/article/canadian-citizenship-americans-new-law-5b8f7da8ce6cfea759b85a3577150407
2•geox•15m ago•1 comments

Keycloak in Production: On-Prem, IaaS, PaaS, or SaaS

https://www.cloud-iam.com/post/keycloak-in-production/
1•Cloud-IAM•22m ago•0 comments

The Download: introducing the Nature issue

https://www.technologyreview.com/2026/04/23/1136346/the-download-introducing-nature-issue/
1•joozio•22m ago•0 comments

Why drawing eyes on food packaging could stop seagulls stealing your chips

https://theconversation.com/why-drawing-eyes-on-food-packaging-could-stop-seagulls-stealing-your-...
1•PaulHoule•23m ago•0 comments

Lawsuit: Nintendo is getting tariff refunds–customers should get them instead

https://arstechnica.com/tech-policy/2026/04/lawsuit-nintendo-is-getting-tariff-refunds-its-custom...
6•LorenDB•23m ago•0 comments

Iran war revives European rooftop solar demand to cut energy bills

https://www.reuters.com/sustainability/climate-energy/iran-war-revives-european-rooftop-solar-dem...
5•rustoo•24m ago•0 comments

Sessa: An alternative to Transformers and Mamba for long-context LLMs

https://github.com/LibratioAI/sessa
1•guyfloki•26m ago•0 comments

Raylib v6.0

https://github.com/raysan5/raylib/releases/tag/6.0
3•rydgel•26m ago•0 comments

Psilocybin just passed phase 3 for depression

https://6th.tech/en/blog/psilocybin-phase-3-depression-drug-free-alternatives
2•smanuel•28m ago•0 comments

Change Orders – Get the Signature Before You Pick Up the Tool

https://www.documentorium.com/blog/change-orders-get-the-signature-before-you-pick-up-the-tool
2•documentorium•29m ago•0 comments

Surveillance vendors caught abusing access to telcos to track people's locations

https://techcrunch.com/2026/04/23/surveillance-vendors-caught-abusing-access-to-telcos-to-track-p...
26•mentalgear•31m ago•2 comments

AI Assistance Reduces Persistence and Hurts Independent Performance

https://arxiv.org/abs/2604.04721
2•ihrimech•33m ago•0 comments

802.1Qav – Forwarding and Queuing Enhancements for Time-Sensitive Streams

https://www.ieee802.org/1/pages/802.1av.html
1•Lwrless•33m ago•0 comments

Because Webfetch Sucks

https://github.com/bxxd/mcp-fetch-ux
1•breed101•35m ago•1 comments

The Ever-changing Art of the Screensaver (2022)

https://eyeondesign.aiga.org/the-ever-changing-art-of-the-screensaver/
1•arbesman•36m ago•0 comments

Streamable Volumetric Video Is Here on Apple Vision Pro (and It's Wild)[video]

https://www.youtube.com/watch?v=YtFEbNLb4wo
2•ndr42•37m ago•0 comments

The Sinclair ZX Spectrum White Edition

https://www.heise.de/news/The-Spectrum-White-Edition-Eine-Retro-Legende-bekommt-eine-Neuauflage-1...
2•i_don_t_know•37m ago•1 comments

Inter-Process Remote Execution: Low-latency IPC/RPC using merged address spaces

https://libriscv.no/assets/files/Emulator_remote_execution_using_merged_address_spaces-4-6ad2a2b8...
1•ingve•39m ago•0 comments