am Fri, dem 15.09.2006, um 10:06:40 +0200 mailte Andreas Joseph Krogh folgendes:
> I have the following query:
>
> select lower(firstname) || ' ' || lower(lastname) from person
>
> firstname and lastname are VARCHAR
>
> lower() returns NULL when firstname OR lastname is NULL, is this correct?
Yes. You can user coalesce for this:
select coalesce(lower(firstname),'') || ...
HTH, Andreas
--
Andreas Kretschmer
Kontakt: Heynitz: 035242/47215, D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID: 0x3FFF606C, privat 0x7F4584DA http://wwwkeys.de.pgp.net