Search Postgresql Archives

Re: Is there a GoTo ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 1/16/20 2:48 AM, İlyas Derse wrote:
In this function I have to GOTO to a label1, but GOTO keyword is not working, can you please help me in getting the way from which I am able to jump from a particular code to label.
  Thanks...

|CREATEORREPLACE FUNCTIONtest(i integer)RETURNS integer AS$$BEGINIFi<0THENRETURNi +1;ELSEGOTOlabel1;ENDIF<<label1>>RETURNnull;END;$$LANGUAGE plpgsql;|


Are you looking for EXIT?:

https://www.postgresql.org/docs/12/plpgsql-control-structures.html#PLPGSQL-CONDITIONALS
42.6.5.2. EXIT

--
Adrian Klaver
adrian.klaver@xxxxxxxxxxx





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux