Subject RE: [ib-support] CASE statements
Author Thomas Steinmaurer
Hi Arno,

> > > > Does FB support SQL CASE statements?
> > >
> > > CASE statements in SELECT, yes. CASE statements as a structure in
> > > stored procedures, no.
> >
> > Are you sure? CASE in Firebird 1.5 PSQL works for me.
>
> I guess Daniel meant :
>
> CASE TableA.FieldX
> 'BLA1' : BEGIN
> <procedure_statement_block>
> END
> 'BLA2' : BEGIN
> <procedure_statement_block>
> END
> ELSE BEGIN
>
> <procedure_statement_block>
> END
> END
>
> and this isn't possible

Now I see your and problaby others POV. ;-))

Yep, such a control-flow statement isn't available in PSQL, but
as shown in my previous message, CASE can be used e.g. for an
assignement statement.


Regards,
Thomas