David Cressey wrote:
> I can't tell you the number of times programmers have come to me for
help
> with a query
> that produces wrong results, and when I try to change their "select" to
> "select distinct" to see if maybe that's the problem,
Hey, wait a minute.
Usually, it's the other way round.
Some people _always_ run DISTINCT because they are not able to "remove
duplicates" :-)
> I patiently explained to them that I first want to come up with a query
that
> is logically correct, then if necessary, come up with one that's
logically equivalent, but
runs fast.
If "fast" comes first, any program will take longer to be "correct" and
will seldom ever be "clean".


|