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

What Is ProxyBase MPP?

https://proxybase.xyz/blog/what-is-proxybase-mpp
1•m00dy•14m ago•0 comments

Save up to 60% API costs without TOON

https://lesstokens.hive-hub.ai/
1•GuilhermeVNZ•15m ago•1 comments

Add age verification to accounts service

https://gitlab.freedesktop.org/accountsservice/accountsservice/-/merge_requests/176#0b07c0cc4d49b...
3•e145bc455f1•27m ago•0 comments

Israeli startup Thermagix harvesting low grade heat

https://www.calcalistech.com/ctechnews/article/dfpboxzg9
2•tomerbd•28m ago•0 comments

Writing a Verified Postfix Expression Calculator in Ada/Spark

https://pyjarrett.github.io/2025/06/10/postfix-calculator.html
1•notagoodidea•28m ago•0 comments

Re:Do Workouts

https://redoworkouts.com/
1•danielauener•29m ago•0 comments

Ask ChatGPT to pick a number from 1-10000, it generally selects from 7200-7500

https://old.reddit.com/r/ChatGPT/comments/1rz2ooh/i_am_betting_my_house_that_if_you_ask_gpt_to_pick/
4•mellosouls•31m ago•3 comments

World Cup Trophy Theft: Gangsters, Spies and the Dog That Found It

https://www.bloomberg.com/news/articles/2026-03-20/the-1966-world-cup-trophy-theft-gangsters-spie...
1•helsinkiandrew•33m ago•0 comments

Google adds 24-hour wait and mandatory reboot to Android sideloading flow

https://android-developers.googleblog.com/2025/08/elevating-android-security.html
11•dfordp11•42m ago•1 comments

BATorrent – Torrent client that streams video while downloading

https://github.com/Mateuscruz19/BAT-Torrent
1•Mateuscruz19•43m ago•0 comments

DIY AI-powered robot arm

https://www.youtube.com/watch?v=59JTCvpG_Ec
1•mafm•43m ago•1 comments

Show HN: Elastik – treating LLM as an HTTP client in less than 200 lines of code

https://github.com/rangersui/Elastik
1•rangersui•44m ago•0 comments

Operation Cast Thy Bread

https://en.wikipedia.org/wiki/Operation_Cast_Thy_Bread
2•throw310822•48m ago•0 comments

Oxford Time

https://en.wikipedia.org/wiki/Oxford_time
1•Tomte•49m ago•0 comments

Cursor's "in-house model" Composer 2 is Kimi K2.5 with RL on top

https://twitter.com/ns123abc/status/2035058399067435474
1•helloplanets•51m ago•0 comments

We Scaled Kimi K2.5 [video]

https://www.youtube.com/watch?v=CwePo4847ho
1•vinhnx•52m ago•0 comments

Physics-based validation for sensor data before ML training

https://github.com/timbo4u1/S2S
1•s2sphysical•53m ago•0 comments

CalMirror – Stop copy-pasting events across Google Calendars

https://apps.apple.com/us/app/calendar-auto-sync-calmirror/id6759219374
1•hmktsu•53m ago•0 comments

Double-O, agent's best friend

https://github.com/randomm/oo
1•jannniii•1h ago•1 comments

We Trust Strangers More Than Brands – What Neuroscience Tells Us

https://www.proofgateway.com
1•elufadeju•1h ago•0 comments

Ask HN: Has anyone here lived in a war zone?

2•michaelteter•1h ago•0 comments

KuraiMusik – A 24/7 AI Radio Orchestrated with AI, Python and Liquidsoap

https://music.kuraitachi.com/
1•daviddevgt•1h ago•0 comments

Why are we eating slop? [video]

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

Manifestation Machines

https://thefuturistsage.substack.com/p/manifestation-machines
1•Archit_lal_•1h ago•0 comments

Tangled: Tightly Knit Social Coding

https://tangled.org
2•j3s•1h ago•0 comments

Is AI Making Us Stupid? Cal Newport Is Worried

https://www.chronicle.com/article/is-ai-making-us-stupid-cal-newport-is-worried
1•smugma•1h ago•1 comments

I tested every "lifetime" Mac app posted on R/macapps for 7 weeks

https://old.reddit.com/r/macapps/comments/1ryvdei/i_tested_every_lifetime_mac_app_posted_on/
1•saaspirant•1h ago•0 comments

Cal Newport is Worried (put down the ChatGPT)

https://www.chronicle.com/newsletter/the-review/2026-03-16
2•smugma•1h ago•1 comments

Show HN: I created a free LLMs.txt generator

https://kitful.ai/write-tools/llms-txt-generator
1•eashish93•1h ago•0 comments

Trivy Under Attack Again: Widespread GitHub Actions Tag Compromise Exposes

https://socket.dev/blog/trivy-under-attack-again-github-actions-compromise
2•tamnd•1h ago•0 comments