From: Gaetano Mendola <mendola@bigfoot.com>
To: Kancha . <kancha2np@yahoo.com>
To: pgsql-sql@postgresql.org
Subject: Re: replace NULL
Date: Wed, 10 Apr 2002 12:03:34 +0200
Message-ID: <005501c1e076$f9f60fe0$5ce8fea9@GMENDOLA2> (raw)
References: <20020409120003.46895.qmail@web14910.mail.yahoo.com>
"Kancha ." <kancha2np@yahoo.com> wrote:
> Hello
>
> i want to run a select query on a table. eg:
>
> select age from people;
>
> if age is NULL then I want to replace it by some text,
> say "SHY" so the output is like
>
> name age
> me 10
> jane SHY
> jack 32
>
> how do i make this replacement of null value to some text
UPDATE people
SET age = 'SHY'
WHERE age IS NULL;
I hope that the field age is a text field;
Ciao
Gaetano
--
#exclude <windows>
#include <CSRSS>
printf("\t\t\b\b\b\b\b\b");.
printf("\t\t\b\b\b\b\b\b");
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: mendola@bigfoot.com, kancha2np@yahoo.com
Subject: Re: replace NULL
In-Reply-To: <005501c1e076$f9f60fe0$5ce8fea9@GMENDOLA2>
* 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