Hacker News new | ask | show | jobs
by valiant55 247 days ago
It depends when you see it, but I agree that DISTINCT shouldn't be used in production. If I'm writing a one off query and DISTINCT gets me over the finish line sparing me a few minutes then that's fine.
2 comments

Which categories did the user post in? Which projects did the user interact with in the last week? That's all normal DISTINCT usage.
There's nothing wrong with using DISTINCT correctly and it does belong in production. The author is complaining about developers that just put in DISTINCT as a matter of course rather than using it appropriately.