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•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

Ask HN: Encouraging a child's gaming PC build despite fear of gaming addiction?

1•marttt•10m ago•0 comments

Over $5M in donations flowed in after the Lapu-Lapu Day attack. Where it went

https://www.cbc.ca/news/canada/lapu-lapu-donations-analysis-9.7207684
1•wolpoli•16m ago•0 comments

Huawei Unveils Tau (τ) Scaling Law for Transistor and System Breakthroughs

https://www.huawei.com/en/news/2026/5/ieee-iscas-tau-scaling
1•CalmStorm•17m ago•0 comments

Mecha Comet is an open-source hardware, modular Linux handheld computer

https://www.cnx-software.com/2026/01/25/mecha-comet-is-an-open-source-hardware-modular-linux-hand...
1•walterbell•19m ago•0 comments

Companies Are Just a Graph of Algorithms

https://danielmiessler.com/blog/companies-graph-of-algorithms
3•samuel246•20m ago•0 comments

CanYouCalculate

https://canyoucalculate.com
1•sauhard121•23m ago•0 comments

Porting Ytdlp to Bun (Ytdlb)

https://yamada-blog.pages.dev/blog/0007/
1•curliness•24m ago•0 comments

Software supply-chain attacks are no longer rare events

https://www.wired.com/story/teampcp-software-supply-chain-attack-spree-github/
2•latentframe•24m ago•1 comments

What is Git made of? (2022)

https://zserge.com/posts/git/
1•vinhnx•26m ago•0 comments

RLS sounds great until it isn't

https://planetscale.com/blog/rls-sounds-great-until-it-isntp
1•eigenBasis•27m ago•0 comments

Jira Is Turing-Complete

https://seriot.ch/computation/jira.html
1•vinhnx•27m ago•0 comments

Show HN: Live AI music sequencing agent

https://pretzel.shukant.com/?nickname=Anonymous&role=stage
1•shukantpal•28m ago•0 comments

A Cattle Ranch Is Doing What Ivy League Colleges Can't

https://www.nytimes.com/2026/05/20/opinion/deep-springs-college-ivy-league-education.html
1•gmays•29m ago•0 comments

The Eternal Sloptember

https://geohot.github.io//blog/jekyll/update/2026/05/24/the-eternal-sloptember.html
2•razin•34m ago•0 comments

My friend found idle NAT gateways his team said didn't exist

https://getnable.com/
1•chaandannn•39m ago•1 comments

AI Interpretability Is a Revolutionary Skill

https://www.outcryai.com/research/the-dark-between-the-stars
1•micahwhite•39m ago•1 comments

High-efficiency multi-scale holographic volumetric 3Dprinting with a phase light

https://www.nature.com/articles/s41377-026-02331-4
1•anikoghosyan•41m ago•0 comments

PaaS Platfrom to Deploy Apps

https://nept.cloud
1•nazmussamir•48m ago•0 comments

Command A+: Making sovereign agentic capabilities available to all

https://cohere.com/blog/command-a-plus
1•offbyone42•50m ago•0 comments

Splinter Cell veteran says realistic modern lighting has screwed up stealth game

https://www.rockpapershotgun.com/splinter-cell-veteran-says-realistic-modern-lighting-has-screwed...
3•Tomte•51m ago•0 comments

Weight loss drugs could save airlines money on fuel as Americans slim down

https://www.cbsnews.com/news/weight-loss-drugs-glp1s-airlines-fuel-costs/
1•mattas•56m ago•2 comments

Everlane Finalizes Sale to Shein

https://www.nytimes.com/2026/05/22/style/shein-everlane-fast-fashion-sustainability.html
1•lxm•58m ago•0 comments

Robotaxis Aren't as Autonomous as They Seem

https://junkoyoshidaparis.substack.com/p/robotaxis-arent-as-autonomous-as
2•mattas•59m ago•0 comments

Kids are Graduating Without Being Able to Read [video][34 mins]

https://www.youtube.com/watch?v=PcSApLcxpYc
1•Bender•1h ago•0 comments

Workspace Orchestration

https://hyperspeed.work
2•Asadsangabi•1h ago•1 comments

DeepSeek-V4 KV Cache Explained: Why 1M Context Uses Less VRAM

https://knightli.com/en/2026/05/18/deepseek-v4-kv-cache-compressed-attention/
1•vinhnx•1h ago•0 comments

Lynote Humanize Text – Open-source AI text humanization toolkit

https://github.com/lynote-ai/humanize-text
2•Danny6969•1h ago•0 comments

MetalBench – Benchmark for Apple Silicon's Metal Shading Lang

https://github.com/Lazarus-931/MetalBench
1•AlazarManakelew•1h ago•1 comments

Irb-autosuggestions: Fish-like autosuggestions for irb

https://github.com/unurgunite/irb-autosuggestions
2•thunderbong•1h ago•0 comments

GKN Aerospace – Hazard Zone Simulator - Garden Grove Chemical Tank Emergency

https://joevezzani.github.io/hazard-zone-sim/
1•palidanx•1h ago•0 comments