Skip site navigation (1) Skip section navigation (2)

ORDER BY and NULLs

From: T E Schmitz <mailreg(at)numerixtechnology(dot)de>
To: pgsql-sql(at)postgresql(dot)org
Subject: ORDER BY and NULLs
Date: 2004-09-19 14:57:33
Message-ID: 414D9E5D.8070708@numerixtechnology.de (view raw or flat)
Thread:
Lists: pgsql-sql
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

Responses

pgsql-sql by date

Next:From: terryDate: 2004-09-19 15:17:31
Subject: Re: ORDER BY and NULLs
Previous:From: GeoffreyDate: 2004-09-19 12:01:55
Subject: Re: How to check postgres running or not ?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group