pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: T E Schmitz <mailreg@numerixtechnology.de>
To: pgsql-sql@postgresql.org
Subject: ORDER BY and NULLs
Date: Sun, 19 Sep 2004 15:57:33 +0100
Message-ID: <414D9E5D.8070708@numerixtechnology.de> (raw)

Hello,

I am using PostgreSQL 7.4.2 and as I understand NULL values always sort 
last.

However, I have a table from which select using two numerical sort keys 
"FROM" and "TO". "TO" might be NULL and I would like to display those 
rows first (without sorting the column in descending order).

Is there any way this can be achieved without inserting bogus values 
into that column?

-- 


Regards/Gruß,

Tarlika Elisabeth Schmitz



view thread (16+ messages)  latest in thread

Message-ID: <414D9E5D.8070708@numerixtechnology.de>
Permalink:  ../414D9E5D.8070708@numerixtechnology.de/
Also on:    postgresql.org/message-id/414D9E5D.8070708@numerixtechnology.de

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: mailreg@numerixtechnology.de
  Subject: Re: ORDER BY and NULLs
  In-Reply-To: <414D9E5D.8070708@numerixtechnology.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox