On Fri, Feb 14, 2014 at 9:20 PM, Antoine Pitrou <solip...@pitrou.net> wrote:
> Hmm, it seems you're right, but I'm quite sure some DBMSes have a
> consistent way of ordering NULLs when using ORDER BY on a nullable
> column.

Yes, and I believe it's part of the SQL-92 spec. Certainly here's
PostgreSQL's take on the matter:

http://www.postgresql.org/docs/9.3/static/sql-select.html#SQL-ORDERBY

In short, NULL is by default considered greater than anything else
(last in an ascending sort, first in a descending sort), but this can
be inverted. Oddly enough, the syntax is NULLS FIRST vs NULLS LAST,
not NULLS LOW vs NULLS HIGH.

ChrisA
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to