Re: syntax error on Function return setoff

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Garry Chen <gc92(at)cornell(dot)edu>
Cc: Andreas Kretschmer <andreas(at)a-kretschmer(dot)de>, "pgsql-novice(at)lists(dot)postgresql(dot)org" <pgsql-novice(at)lists(dot)postgresql(dot)org>
Subject: Re: syntax error on Function return setoff
Date: 2018-01-29 13:56:50
Message-ID: CAKFQuwZRtJj4PdrGfSXJ2ZQQQHyh8hnpuVA_NJ-tZ6+hLXMqNw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Mon, Jan 29, 2018 at 6:42 AM, Garry Chen <gc92(at)cornell(dot)edu> wrote:

> Hi Andreas,
> Thank you very much for your reply. Very strange, in 9.6 the
> function created/compiled successful without the table called
> "acct_nbr_lst". But in release 10 this table "acct_nbr_lst" must exist in
> order to create/compiled this function. In RDBMS function/procedure
> coding principal, I don’t know which one is the correct way. Is there any
> Postgresql documents that states/mentation the prerequisite about the
> SETOF? Once again thank you very much for your help.
>

​Anything outside of the string-literal function body (which includes the
RETURNS clause) has to exist and is recorded as a dependency. The material
within a function body usually (not sure if/when expections...) is not
required to exist and is not recorded as a dependency.​

David J.

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message David G. Johnston 2018-01-30 01:14:54 Re: STATISTICS retained in CREATE TABLE ... LIKE (INCLUDING ALL)?
Previous Message Garry Chen 2018-01-29 13:42:18 Re: syntax error on Function return setoff