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

Show HN: We map free text to NEO PI-R personality facets

https://sentino.org/blog/personality-api/the-science-behind-every-sentino-score/
1•Sentino_Psy_API•56s ago•0 comments

AI Brain Fry Is Real, and Devs Are Fighting Back – What's Up Devs? #8

https://wud.happyto.dev/p/what-s-up-devs-8-ai-brain-fry-is-real-and-devs-are-fighting-back
1•happytodev•1m ago•0 comments

Original iPhone Loses Its Last Cellular Network as T-Mobile Kills 2G

https://www.macrumors.com/2026/08/06/t-mobile-2g-network-disabled/
1•thm•2m ago•0 comments

Ask HN: What is a good advice for someone looking to fractional hire a team?

2•vanessa1211•6m ago•0 comments

Heatwave forces power plant shutdowns across Europe, putting grid under strain

https://www.lemonde.fr/en/economy/article/2026/08/07/heatwave-forces-power-plant-shutdowns-across...
2•geox•10m ago•0 comments

Slackrastination (2018)

https://www.lepekhin.com/2018/07/30/Slack-rant
1•bizzz•10m ago•0 comments

Show HN: Akintu – AI agents trained on custom knowledge bases using RAG

https://akintu.ai
1•Sharanxxxx•11m ago•0 comments

Design Systems in the Age of AI: Five Working Hypotheses

https://uxdesignresearch.org/en/5-hypotheses/
2•agilek•11m ago•0 comments

A Chrome extension that magically autofills job applications from your CV

https://chromewebstore.google.com/detail/resume-autofill-for-job-a/hianlncojnfigojgoaooegapjphndgaa
1•javier_yc_new•12m ago•1 comments

Re-rasterization-free variable font morphing (knot-lattice blend)

https://github.com/GitBruno/VarFont
1•ChaosBender•12m ago•0 comments

The Witch of Agnesi

https://en.wikipedia.org/wiki/Witch_of_Agnesi
1•monarchkumar•12m ago•0 comments

1 mL of the mass killing of an ethnic group

https://twitter.com/addictedtoigno1/status/2085343928778133875
1•delichon•15m ago•0 comments

Basilisk has been removed from the Python typing conformance leaderboard

https://github.com/python/typing/pull/2330
3•pythontyper•18m ago•1 comments

Tryall –- describe the task, and it picks the AI model for you

https://www.tryall.ai
2•nikvaklinov•19m ago•0 comments

Show HN: Cleaner speaker identification for in-person meeting transcripts

https://apps.apple.com/us/app/ellis-in-person-ai-notes/id6753657763
1•robinyapockets•20m ago•1 comments

Pyrefly 1.2 is here – feat. Bazel support, attrs, and type coverage checking

https://pyrefly.org/blog/v1.2/
2•ocamoss•20m ago•0 comments

UX Design Research – reflections on the role of UX design in the age of AI

https://uxdesignresearch.org/en/
2•kachnuv_ocasek•21m ago•0 comments

Show HN: A local-first iOS planner I built to replace my calendar and todo apps

https://apps.apple.com/ph/app/zesfy-to-do-list-day-planner/id6479947874
1•zesfyapp•23m ago•0 comments

The AI Cost Rebellion Is About Unit Economics

https://www.voxelperfect.com/writing/the-ai-cost-rebellion-is-really-about-unit-economics
1•voxelperfect•27m ago•0 comments

My Space Cadet Pinball Machine Finally Has Wormholes! [video]

https://www.youtube.com/watch?v=_wvKlX_NsGk
1•skibz•29m ago•0 comments

GrapheneOS says Revolut is blocking its users over Google Play checks

https://grapheneos.social/@GrapheneOS/117045625230764434
6•DeepLogin•30m ago•0 comments

Show HN: Job Search Automation Agent with a Human in the Loop

https://rehiredd.com
1•kan101•31m ago•0 comments

JJ2+ – Jazz Jackrabbit 2 mod

https://jj2.plus/website.php
1•skibz•34m ago•0 comments

Worms: The Future of Yesterday's Worms Today

https://worm.net/
1•doener•34m ago•0 comments

From LLM to shopping cart (Portugal)

https://cesta.pt/
1•marcogarces•34m ago•0 comments

The Gargantuan Lie That Is Collapsing the Climate

https://www.currentaffairs.org/news/the-massive-climate-lie-that-will-destroy-human-civilization
36•Anon84•35m ago•11 comments

AI Meet CAD: Beat Opus/Mythos 5, GPT 5.6 Sol on BenchCAD

https://arxiv.org/abs/2608.00799
1•SUPERustam•37m ago•1 comments

Indie dev claims Gemini leaked scarily specific details in private documents

https://www.gamesradar.com/games/google-ai-leaks-scarily-accurate-and-very-specific-game-detail-f...
2•Sha1rholder•38m ago•0 comments

You are a kitten in a catnip forest

https://kittensgame.com/web/
1•xkcd1963•41m ago•0 comments

"Aura" and the Backlash Against the Slop Machine

https://decodingvibes.com/blog/aura-and-the-backlash-against-the-slop-machine/
1•altmanaltman•43m ago•0 comments