Re: [Pgsql-ayuda] Conditional execution: IF

From: Gunnar Wolf <gwolf(at)gwolf(dot)cx>
To: sandrigo lezcano <psql(at)msa(dot)com(dot)py>
Cc: Pgsql-ayuda(at)tlali(dot)iztacala(dot)unam(dot)mx
Subject: Re: [Pgsql-ayuda] Conditional execution: IF
Date: 2003-06-27 00:32:59
Message-ID: 20030627003259.GU4014@gwolf.cx
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

sandrigo lezcano dijo [Fri, Jun 27, 2003 at 12:17:26AM +0100]:
> en Sybase tengo una:
>
> Conditional execution: IF
>
> IF condition THEN
> Statement-list
> ELSEIF condition THEN
> Statement-list
> ELSE
> Statement-list
> END IF
>
> No he visto en PostgreSQL...
> ...es tan complicado encontrar
> cualquier cosa..

¿Complicado?

http://www.postgresql.org/docs/view.php?version=7.3&idoc=1&file=plpgsql-control-structures.html#PLPGSQL-CONDITIONALS
-----------------------------------
19.6.2. Conditionals

IF statements let you execute commands based on certain conditions.
PL/pgSQL has four forms of IF:

*

IF ... THEN
*

IF ... THEN ... ELSE
*

IF ... THEN ... ELSE IF and
*

IF ... THEN ... ELSIF ... THEN ... ELSE
-----------------------------------

Exactamente igual ;-)

--
Gunnar Wolf - gwolf(at)gwolf(dot)cx - (+52-55)5630-9700 ext. 1366
PGP key 1024D/8BB527AF 2001-10-23
Fingerprint: 0C79 D2D1 2C4E 9CE4 5973 F800 D80E F35A 8BB5 27AF

In response to

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message Carlos 2003-06-27 01:00:07 RE: [Pgsql-ayuda] ayuda Postgres - enviar solo registros modificados y creados en el dia de un BD
Previous Message Adrian Galindo 2003-06-27 00:16:03 Re: [Pgsql-ayuda] Conexiones ociosas