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

Combining freelancing, social networking, and AI

https://freelancer.svoxx.com/int/en
1•svoxx•2m ago•0 comments

Developers say they didn't know user data went to the government

https://404privacy.com/blog/app-developers-say-they-didnt-know-user-data-went-to-the-government/
1•un-nf•2m ago•1 comments

QueCarrera – Pick a university degree in Madrid, with cut-off grades

https://quecarrera.vercel.app
1•gustavogb•4m ago•0 comments

Anthrax outbreak in Africa's oldest national park kills hippos

https://abcnews.com/International/anthrax-outbreak-virunga-national-park-kills-dozens-hippos/stor...
1•gmays•4m ago•0 comments

A Man Who Conned the World

https://foreignpolicy.com/2023/12/03/con-artist-global-scam-ghana-anansis-gold/
1•prmph•8m ago•0 comments

1994 After Dark Files Rat Race, Ported to the Browser

https://rat-race.heyitsjam.es/
1•shijie•10m ago•0 comments

Elon Musk is about to learn how much America hates him

https://www.independent.co.uk/voices/elon-musk-donald-trump-midterms-republican-starlink-b3079726...
4•Zigurd•14m ago•0 comments

What Is Pico Ballooning?

https://traquito.github.io/pico-balloons/
1•gregsadetsky•14m ago•0 comments

US warns China it must 'immediately' meet terms of Busan trade deal

https://www.ft.com/content/391bb785-0247-4c39-b53b-35007187d603
2•madihaa•15m ago•0 comments

Mineral-forming method removes over 99% of radioactive technetium from waste

https://phys.org/news/2026-11-mineral-method-radioactive-technetium-liquid.html
2•titusblair•15m ago•0 comments

Ask HN: Are AI-written reviews a safety risk? Evidence from ICLR2027 scores

1•fsabau•16m ago•0 comments

Show HN: We built an async interview engine to get published on HackerNoon

https://journalistic.tech/
1•smooke•16m ago•0 comments

Show HN: Realtime sync engine without any new infra

https://github.com/tanishqkancharla/tandem
1•tanishqkanc•18m ago•0 comments

New Research Tests Whether AI Models Know Their Own Thoughts

https://www.quantamagazine.org/new-research-tests-whether-ai-models-know-their-own-thoughts-20261...
1•dogscatstrees•19m ago•0 comments

How I Learned to Stop Worrying and Love AI

https://koenvangilst.nl/lab/how-i-stopped-worrying-and-learned-to-love-ai
3•vnglst•20m ago•0 comments

FMF Jailbreak Rating Framework for Frontier Cyber Threats

https://www.frontiermodelforum.org/updates/introducing-the-fmf-jailbreak-rating-framework-for-fro...
1•pretext•20m ago•0 comments

Anthropic to press ahead with November IPO targeting $1.5T valuation

https://www.ft.com/content/314e17df-e7af-4814-b208-70a0557cb452
3•mfiguiere•20m ago•0 comments

Ballast – cold email infrastructure with AI and MCP

https://ballast.to
1•yetanotherdevz•20m ago•1 comments

Teaching AI to build scientific models

https://www.anthropic.com/research/teaching-ai-to-build-scientific-models
2•pretext•21m ago•0 comments

End of the Internet

https://stratechery.com/2026/the-end-of-the-internet/
3•Karrot_Kream•23m ago•0 comments

I watched a humanoid robot clean my apartment. Like a taste of the future

https://www.technologyreview.com/2026/11/06/1148090/i-watched-a-humanoid-robot-clean-my-apartment...
2•gnabgib•24m ago•0 comments

Hacking the meta ray-ban smartglasses

https://p0pcycle.com/2026/11/06/hacking-the-meta-ray-ban-smartglasses/
1•sshah03•25m ago•0 comments

The Components of Agent Memory

https://www.anthropic.com/research/components-of-agent-memory
2•mfiguiere•27m ago•0 comments

The Yak Is Shaved

https://oddbits.ai/blog/the-yak-is-shaved/
1•wfalcon•27m ago•1 comments

Implant 0.4.0 Is Out

https://marketplace.visualstudio.com/items?itemName=strangepleasures.implant
1•strangepleasure•27m ago•1 comments

Tell HN: Be Careful with Stripe Connect

5•breue•30m ago•0 comments

LZ4 1.11 Introduces Multi-Threaded Compression for Liblz4, Other Gains

https://www.phoronix.com/news/LZ4-1.11-Released
3•Bender•31m ago•0 comments

The Web Is More Than Enough

https://ftrain.com/aboard-the-web-is-more-than-enough
2•bookofjoe•32m ago•0 comments

88x31 GIF Stickers for 2026

https://a90.com/experiments/88x31/
3•saint11•33m ago•0 comments

The End of AI Frontiers

https://hunch.net/?p=13764006
1•gmays•35m ago•0 comments