Hacker News new | ask | show | jobs
by josephg 662 days ago
What you're describing is a straightforward indexing problem. There's nothing stopping the database building an index which can look up customer IDs for a given order ID. You could even, if the database allows it, build a virtual ORDER table projection that you could query directly.