A very small update.
>>>>> "Sergei" == Sergei Golubchik <serg@stripped> writes:
>> Thanks, although I'm still wondering about why the NULL-always-sorts-first
>> change was made for 4.0.2. Wasn't that done for ANSI compliance? Did
>> the ANSI spec change?
Sergei> ANSI X3.135-1992 (Database Language SQL) in section 13.1, General
Sergei> Rule 3)b), page 309, says "Whether a sort key value that is null is
Sergei> considered greater or less than a non-null value is implementation-
Sergei> defined, but all sort key values that are null shall either be
Sergei> considered greater than all non-null values or be considered less than
Sergei> all non-null values."
The problem is that the above doesn't spell out how NULL is affected
by DESC. As NULL can't be compared and are not ordered (by
definition) it's not clear from the above (at least to me) what DESC
is supposed to do.
Anyway, as Sergei said, the current (changed) behaviour is probably
what ANSI SQL means and is most like the way most other database is
handling DESC with NULL. Sorry again for the confusion....