Re: cursors and function question

From: armand pirvu <armand(dot)pirvu(at)gmail(dot)com>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: cursors and function question
Date: 2018-02-14 02:58:27
Message-ID: 1CC76001-D74C-49A0-AC7F-2DE8AAC047C7@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


> On Feb 13, 2018, at 4:37 PM, David G. Johnston <david(dot)g(dot)johnston(at)gmail(dot)com> wrote:
>
> On Tue, Feb 13, 2018 at 3:31 PM, Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com <mailto:adrian(dot)klaver(at)aklaver(dot)com>> wrote:
> 2) By global table do you mean a temporary table? If so not sure that is going to work as I am pretty sure it will disappear after the function is run.
>
> ​Temporary tables can survive until either session or transaction end - neither of which occurs automatically when exiting a function.
>
> https://www.postgresql.org/docs/10/static/sql-createtable.html <https://www.postgresql.org/docs/10/static/sql-createtable.html>
>
> "Temporary tables are automatically dropped at the end of a session, or optionally at the end of the current transaction (see ON COMMIT below)"
>
> David J.
>

Thank you both of you Adrian and David for the input and help

I owe you some nice red wine :)

Cheers
- Armand

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Jeremy Finzel 2018-02-14 05:41:10 Re: pglogical in postgres 9.6
Previous Message Welkin 2018-02-14 01:51:18 unsubsribe