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

Women sue the men who used their Instagram feeds to create AI porn influencers

https://www.wired.com/story/ai-porn-lawsuit-arizona/
1•Bender•33s ago•0 comments

Minnesota passes ban on fake AI nudes; app makers risk $500K fines

https://arstechnica.com/tech-policy/2026/05/minnesota-set-to-be-first-state-to-ban-nudification-a...
1•Bender•1m ago•0 comments

WolfCOSE vs. the Field: The Smallest, Most Complete COSE Implementation

https://aidangarske.github.io/wolfCOSE/blog/wolfcose-vs-the-field/
1•aidangarske•1m ago•1 comments

Fredis: A simple in-memory Redis compatible server in Rust

https://gitlab.com/foscogab/fredis
1•gfosco•4m ago•1 comments

AI as Infrastructure

https://cunderwood.dev/2026/05/01/ai-as-infrastructure/
2•speckx•5m ago•0 comments

How to speed up clinical trials (Works in Progress Podcast)

https://podcasts.apple.com/us/podcast/how-to-speed-up-clinical-trials/id1819488714?i=1000763007270
1•marojejian•6m ago•1 comments

Top AI companies agree to work with Pentagon on secret data

https://www.washingtonpost.com/technology/2026/05/01/pentagon-ai-deals-microsoft-amazon-google-cl...
1•geox•6m ago•0 comments

Musk Warns of Killer AI, While He and Silicon Valley Cash in on AI That Kills

https://theintercept.com/2026/05/01/elon-musk-openai-lawsuit-trial/
2•cdrnsf•7m ago•0 comments

The California Government Is Coming for Your E-Bikes

https://sfstandard.com/2026/04/30/e-bike-regulation-license-plates-laws-dmv/
2•m463•7m ago•0 comments

Using "underdrawings" for accurate text and numbers

https://samcollins.blog/underdrawings/
2•samcollins•9m ago•1 comments

Claude Code can now /perceive

https://github.com/machinepulse-ai/world2agent
2•WayLonWen•9m ago•0 comments

An Interview with Josh Fisher – Inventing VLIW, Multiflow, Itanium [video]

https://www.youtube.com/watch?v=ZF8ohzWmuzI
1•dataviz1000•11m ago•0 comments

Show HN: Blotter, a live map of police radio activity

https://blotter.fm
1•s_e__a___n•12m ago•1 comments

Andrej Karpathy's Sequoia talk, I agree with most but not this

https://twitter.com/xing101/status/2050271353983598630
3•xingwu•14m ago•2 comments

Show HN: BeautyShot – easy macOS promo screenshots

https://bendansby.com/apps/beautyshot/
1•webwielder2•14m ago•0 comments

Farrell vs. LinkedIn Corporation 4:26-CV-02953-KAW (ND Cal Apr 6, 2026) [pdf]

https://ia601503.us.archive.org/33/items/gov.uscourts.cand.467271/gov.uscourts.cand.467271.1.0.pdf
1•1vuio0pswjnm7•14m ago•0 comments

LLM-eval-kit: Distributed LLM evaluation framework (v0.3.0)

https://github.com/benmeryem-tech/llm-eval-kit
1•benmeryem_ai•16m ago•0 comments

Achi RPC: An RPC library for workers on the web and node JavaScript

https://www.npmjs.com/package/achi-rpc
1•stiles11•18m ago•0 comments

"I suck" -theprimeagen [video]

https://www.youtube.com/watch?v=V-ZvAw_VNk4
1•eamag•18m ago•0 comments

Ganglion: Hostile-network reachability for robot fleets, built on libp2p

https://github.com/TafyLabs/ganglion
1•karma0•20m ago•1 comments

Y Combinator alum Skio sells for $105M cash, only raised $8M, founder says

https://techcrunch.com/2026/04/30/y-combinator-alum-skio-sells-for-105m-cash-only-raised-8m-found...
3•Brajeshwar•22m ago•0 comments

TypeKro: Write TypeScript. Deploy Kubernetes

https://typekro.run
2•ManWith2Plans•24m ago•0 comments

Pentagon reaches agreements with top AI companies, but not Anthropic

https://www.reuters.com/business/retail-consumer/pentagon-reaches-agreements-with-leading-ai-comp...
2•mikhael•27m ago•0 comments

It's Possible to Learn in Our Sleep. Should We?

https://www.newyorker.com/culture/annals-of-inquiry/its-possible-to-learn-in-our-sleep-should-we
2•XzetaU8•29m ago•1 comments

Decoding a decade of rising global light pollution

https://www.darkskyconsulting.com/blog/decoding-a-decade-of-rising-global-light-pollution
2•DamonHD•31m ago•0 comments

Show HN: CyberChef Payment Cryptography Extensions

https://www.jacobmarks.com/2026/04/cyberchef-payment-cryptography.html
1•J8K357R•31m ago•0 comments

Show HN: AI CAD Harness

https://fusion.adam.new/install
2•zachdive•32m ago•0 comments

Show HN: My Private GitHub on Postgres

https://github.com/calebwin/gitgres
8•calebhwin•36m ago•2 comments

Artemis II Fault Tolerance

https://alearningaday.blog/2026/05/01/artemis-ii-fault-tolerance/
2•speckx•37m ago•0 comments

MetaModel – AI builds structured, formula-driven apps from plain English

https://www.metamodel.app
1•joegra•37m ago•0 comments