J
James Palmer
Guest
find first is fine if you genuinely couldn't care which record you get if there are multiple. I suppose it's fine if you're searching on a unique index (although that might change in future). The point of find without the first is that if you have multiple results satisfying the where clause you handle that and inform the user that something is wrong rather than making an assumption. I always used find first before, and likewise was never bitten. BUT, having changed my ways to omit the first I have encountered a number of situations where I /could/ have been bitten.
Continue reading...
Continue reading...