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

Calif. lawsuit accuses Meta of sending nude video from AI glasses to workers

https://www.sfgate.com/tech/article/meta-ai-glasses-lawsuit-21960004.php
1•c420•1m ago•0 comments

Show HN: BeyondComments – Find content ideas and signals from YouTube comments

https://beyondcomments.io
1•ProgrammerByDay•4m ago•0 comments

Show HN: Sajtanalys.se – Automated website analysis for Swedish businesses

https://sajtanalys.se
1•qvalitet•4m ago•0 comments

The Day NY Publishing Lost Its Soul

https://www.honest-broker.com/p/the-day-ny-publishing-lost-its-soul
1•wallflower•5m ago•0 comments

Tropes.md

https://tropes.fyi/tropes-md
1•walterbell•6m ago•0 comments

Palmer Luckey's $1B pitch to reboot 1990s video game consoles

https://www.ft.com/content/77e330a5-8e59-4a36-b08b-c18010a2383b
2•hackerbeat•6m ago•1 comments

MicroBin – Easy File Sharing for Everyone – Self-Hostable

https://my.microbin.eu/
1•dszb•7m ago•0 comments

SWE-CI: Evaluating Agent Capabilities in Maintaining Codebases via CI

https://arxiv.org/abs/2603.03823
1•stepri•11m ago•0 comments

I Failed an Interview. Fair or Not, I Built This Workbook

https://doap.metal.bohyen.space/blog/post/java-fintech-interview-workbook/
2•nanacnote•12m ago•1 comments

Sunflowers

https://napo.dev/sunflowers/
1•napolux•16m ago•0 comments

Senators Launch Effort Ban Elected Officials Profiting from Prediction Markets

https://www.merkley.senate.gov/merkley-klobuchar-launch-new-effort-to-ban-federal-elected-officia...
11•stopbulying•19m ago•3 comments

Show HN: ShareNova – Zero-knowledge file transfer with magic-byte scanning

2•HatemDabet•23m ago•0 comments

Show HN: Luna Agent – Custom AI agent in ~2300 lines of Python, no frameworks

https://nonatofabio.github.io/blog/post.html?slug=luna_agent
1•nonatofabio•25m ago•0 comments

Drink the Radioactive Gatorade (AI Pilled)

https://twitter.com/SparksZilla/status/2030336440987463837
1•rmason•25m ago•0 comments

Homo Ignorans: Deliberately Choosing Not to Know

https://pubmed.ncbi.nlm.nih.gov/27217249/
4•Jimmc414•26m ago•2 comments

The False Flag of Viewpoint Diversity

https://www.chronicle.com/article/the-false-flag-of-viewpoint-diversity
1•mmooss•26m ago•0 comments

Prompt Guidance for GPT-5.4

https://developers.openai.com/api/docs/guides/prompt-guidance/
1•andromaton•26m ago•1 comments

Astronomers are capturing video of a black hole for the first time

https://www.cbc.ca/lite/story/9.7117478
1•colinprince•27m ago•0 comments

Do developers even give feedback?

2•xerrs•31m ago•2 comments

CasNum

https://github.com/0x0mer/CasNum
20•aebtebeten•31m ago•4 comments

Lunch with Lord Mancroft

https://www.ft.com/content/ab4d34b3-b73a-48a6-8654-6792c9c39d20
1•theopsimist•32m ago•0 comments

Show HN: Meshcraft – Text-to-3D and image-to-3D with selectable AI engines

https://meshcraft.xyz
1•otmardev•33m ago•0 comments

Show HN: AICurate – AI news curation platform for associations

https://www.aicurate.news
1•eibrahim•33m ago•0 comments

Show HN: Custom Git-receive-pack implementation

https://github.com/runxiyu/furgit/tree/master/cmd/receivepack9418
1•runxiyu•34m ago•0 comments

Rust: The Unlikely Engine of the Vibe Coding Era

https://www.forbes.com/councils/forbestechcouncil/2026/03/03/rust-the-unlikely-engine-of-the-vibe...
3•rbanffy•34m ago•0 comments

AI Will Reshape Public Opinion

https://www.conspicuouscognition.com/p/how-ai-will-reshape-public-opinion
1•gmays•34m ago•0 comments

Customs checks tank tourists at border crossings

https://www.welt.de/vermischtes/article69abe97c10f264d559776f38/hohe-spritpreise-zoll-kontrollier...
3•cwwc•35m ago•0 comments

NanoGPT Speedrun Living Worklog

https://www.tylerromero.com/posts/nanogpt-speedrun-worklog/
2•jxmorris12•37m ago•0 comments

AI agents are having an Android camera moment

https://zoi.leaflet.pub/3mgimwyo7bs2x
1•404salad•38m ago•0 comments

The Invisible Web

https://leadprompt.sh/a/726-The-Invisible-Web-2026w6
1•saltysalt•38m ago•0 comments