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

AI will optimize everything except your life. That's still on you

https://indignified.substack.com/p/ai-will-optimize-everything-except
1•ZguideZ•1m ago•0 comments

A Choice of Deadly Drones Is Only a Few Clicks Away

https://www.nytimes.com/2026/03/23/world/europe/ukraine-drones-marketplace-military-russia.html
1•lxm•5m ago•0 comments

LLM autonomously runs physics research across 5 PDE systems

https://github.com/michK/Autoresearch-for-Research
1•mike_krugs•6m ago•1 comments

Researchers at CERN transport antiprotons by truck in world‑first experiment

https://physicsworld.com/a/researchers-at-cern-transport-antiprotons-by-truck-in-world-first-expe...
1•oopsiremembered•12m ago•0 comments

WildClawBench

https://github.com/InternLM/WildClawBench
1•yhzan•12m ago•0 comments

AcademySoftwareFoundation DNA

https://github.com/AcademySoftwareFoundation/dna
1•qainsights•13m ago•1 comments

Meta's May Day

https://om.co/2026/03/25/metas-may-day/
2•gz5•16m ago•0 comments

Scammers have virtual smartphones on speed dial for fraud

https://www.theregister.com/2026/03/25/virtual_smartphones_fraud/
1•Brajeshwar•17m ago•0 comments

Show HN: Nit – I rebuilt Git in Zig to save AI agents 71% on tokens

https://justfielding.com/blog/nit-replacing-git-with-zig
2•fielding•22m ago•0 comments

Let's Not Confuse Labor's Problems with White-Collar AI Doomerism

https://www.damagemag.com/p/lets-not-confuse-labors-problems
1•abetusk•24m ago•0 comments

The personal relation between Phil K. Dick and Robert Heinlein

https://scifi.stackexchange.com/questions/1555/on-the-personal-relation-between-phil-k-dick-and-r...
1•wslh•26m ago•0 comments

Toggle macOS battery icon with plug/unplug

https://github.com/dceddia/battery-icon-toggle
1•dceddia•29m ago•0 comments

Show HN: Ultrahuman Ring API Dashboard (E-Ink)

https://github.com/Jay9185/TRMNL-ULTRAHUMAN
1•jerr9185•31m ago•1 comments

Mojo's Not (Yet) Python

https://theconsensus.dev/p/2026/03/12/mojos-not-yet-python.html
1•tuananh•34m ago•0 comments

Show HN: LookGood Live – Chrome plugin enhances your appearance on camera video

https://webcameffects.app/en/extensions/looksgood-live/
1•mda_damico•41m ago•0 comments

Meta, Google lose US case over social media harm to kids

https://www.reuters.com/legal/litigation/jury-reaches-verdict-meta-google-trial-social-media-addi...
3•1vuio0pswjnm7•48m ago•1 comments

Six open table formats compared across 5 architectural forks

https://medium.com/@shaoting.huang/the-table-format-wars-4daa6ba3dd84
1•fujidanbao•48m ago•0 comments

Async, Sync, in Between

https://antfu.me/posts/async-sync-in-between
1•luispa•49m ago•0 comments

Comparison of embedding size reduction methods for vector search

https://corvi.careers/blog/vector-search-embedding-compression/
1•sp1982•50m ago•0 comments

Earliest iron blooms discovered off the Carmel coast

https://www.nature.com/articles/s40494-026-02409-7
1•wslh•50m ago•0 comments

Writing Changes Mathematical Thought

https://www.quantamagazine.org/how-writing-changes-mathematical-thought-20260325/
1•sonabinu•51m ago•0 comments

Chinese National and 2 US Citizens Charged W Conspiring to Smuggle AITech to CCP

https://www.justice.gov/opa/pr/chinese-national-and-two-us-citizens-charged-conspiring-smuggle-ar...
1•737min•52m ago•0 comments

Ask HN: Has Claude Code quality level degraded lately?

2•narmiouh•52m ago•1 comments

Weaponizing Extension Packs with PackRAT

https://blog.yeethsecurity.com/2026/03/13/PackRat.html
1•somerandom1337•57m ago•0 comments

LA Jurors Find Meta, YouTube Liable for Youth Mental Health Problems, Award $6M

https://www.law.com/2026/03/25/los-angeles-jurors-find-meta-and-youtube-liable-for-youths-mental-...
2•1vuio0pswjnm7•1h ago•1 comments

Verdicts against social media companies carry consequences. But questions linger

https://www.boston25news.com/news/business/verdicts-against/EZ3JDN546E7RHDQDVPTYYGCAGI/
1•1vuio0pswjnm7•1h ago•0 comments

VS Code plugin to annotate in Markdown previews for your AI

https://github.com/41fred/ai-markdown-feedback
1•41fred•1h ago•1 comments

Web and File Server Comparison (NT Server 4.0 versus RedHat 5.2 on Linux 2.2.2)

http://www.mindcraft.com/whitepapers/first-nts4rhlinux.html
2•markus_zhang•1h ago•0 comments

Isolated Web Apps

https://chromeos.dev/en/web/isolated-web-apps
1•h4ch1•1h ago•0 comments

Every Online Conversation about AI, Summarized

https://rushyendramaganty.com/ai
3•finolex1•1h ago•0 comments