pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jackson, DeJuan <djackson@cpsgroup.com>
To: Eduardo Noeda <enoeda@virtualsw.es>
To: pgsql-sql@postgreSQL.org
Subject: RE: [SQL] IIF..
Date: Mon, 29 Mar 1999 13:20:15 -0600
Message-ID: <D05EF808F2DFD211AE4A00105AA1B5D20376A6@cpsmail> (raw)

It would be:
  SELECT (CASE Number 
           WHEN 1 THEN 'First' 
           ELSE 'Other' 
          END) AS Description
    FROM Table

	-DEJ

> -----Original Message-----
> Hi!
> 
> I'm new in the list (and in PostgreSQL too). I'd like to know 
> if it's posible to perform a function like SQL Server's "iif" 
> in a SELECT query. Some like:
> 
> SELECT iif (Number=1, "First", "Other") AS Description
> FROM Table;
> 
> I don't know if I've explained properly...
> --
> Eduardo Noeda  --  Virtual Software
> enoeda@virtualsw.es



view thread (5+ messages)  latest in thread

Message-ID: <D05EF808F2DFD211AE4A00105AA1B5D20376A6@cpsmail>
Permalink:  ../D05EF808F2DFD211AE4A00105AA1B5D20376A6@cpsmail/
Also on:    postgresql.org/message-id/D05EF808F2DFD211AE4A00105AA1B5D20376A6@cpsmail

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: djackson@cpsgroup.com, enoeda@virtualsw.es
  Subject: Re: [SQL] IIF..
  In-Reply-To: <D05EF808F2DFD211AE4A00105AA1B5D20376A6@cpsmail>
  References: <D05EF808F2DFD211AE4A00105AA1B5D20376A6@cpsmail>

* 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