If test in sql??

From: "Esa Pikkarainen" <epikkara(at)ktk(dot)oulu(dot)fi>
To: pgsql-general(at)postgresql(dot)org
Subject: If test in sql??
Date: 2001-01-24 11:08:33
Message-ID: 67915E45708@ktk.oulu.fi
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

This is maybe a novice question, but after all...
Say, I have a discussion forum application. There is an expiration
value for a whole board; then there are individual values for every
conference. If this individual value is NULL then the general value
should be used. How can I test this situation in a query (to
Postgresql):
I mean something like:

Select (IF conf.expire NOTNULL conf.expire ELSE gen_expire)
as expire, ...

Where is this in manuals if it is?

Thanks
Esa

Browse pgsql-general by date

  From Date Subject
Next Message Oliver Elphick 2001-01-24 11:26:45 Re: [INTERFACES] Can't connect to anonCVS !
Previous Message Zak McGregor 2001-01-24 11:06:30 Re: Re: MySQL has transactions