Re: proposal for 8.4: PL/pgSQL - statement CASE - Mailing list pgsql-hackers

From Brendan Jurd
Subject Re: proposal for 8.4: PL/pgSQL - statement CASE
Date
Msg-id 37ed240d0801171141i7da3936o798a511b951bc689@mail.gmail.com
Whole thread Raw
In response to Re: proposal for 8.4: PL/pgSQL - statement CASE  ("Pavel Stehule" <pavel.stehule@gmail.com>)
List pgsql-hackers
On Jan 18, 2008 3:19 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> > Isn't there a danger of syntactical conflict with the SQL SELECT ... CASE
> > statement?
>
> no, isn't. SELECT CASE can be only in expression .. inside SQL
> statement, but PL/SQL CASE is PL statement. These are two different
> worlds. SELECT CASE is invisible for pl parser, because pl parser
> solves statements, not expressions.
>

Sounds good.  Chaining ELSIFs is ugly; I've wished for something like
this in PL/pgSQL from time to time while writing my functions.

A hearty "+1" from me.  Let me know if there's anything I can do to
help move it forward.

Cheers
BJ


pgsql-hackers by date:

Previous
From: "Kevin Grittner"
Date:
Subject: Re: OUTER JOIN performance regression remains in 8.3beta4
Next
From: Decibel!
Date:
Subject: Re: Thick indexes - a look at count(1) query