Skip site navigation (1) Skip section navigation (2)

Re: Using EXIT and labels to exit blocks of statements

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Danny Lo <lo(dot)dannyk(at)gmail(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Using EXIT and labels to exit blocks of statements
Date: 2010-03-03 00:58:29
Message-ID: 27678.1267577909@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-novice
Danny Lo <lo(dot)dannyk(at)gmail(dot)com> writes:
>> Following error. Just want to know correct way to use label. Thanks very
>> much.

You need to put the <<label>> before the DECLARE, not after --- see the
syntax examples here:
http://www.postgresql.org/docs/8.4/static/plpgsql-structure.html

I think it's a bug that it's not throwing an error for the label
placement as you have it.

			regards, tom lane

In response to

pgsql-novice by date

Next:From: Atif JungDate: 2010-03-03 10:48:31
Subject: Array or not Array?
Previous:From: Danny LoDate: 2010-03-02 21:39:42
Subject: Using EXIT and labels to exit blocks of statements

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group