Re: SPI error with non-volatile functions

From: Andres Freund <andres(at)anarazel(dot)de>
To: Tom Mercha <mercha_t(at)hotmail(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: SPI error with non-volatile functions
Date: 2019-11-13 05:13:59
Message-ID: 20191113051359.yxypcactwnz7uj3q@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On 2019-11-13 05:09:31 +0000, Tom Mercha wrote:
> I've been using SPI to execute some queries and this time I've tried to
> issue CREATE TABLE commands through SPI. I've been getting the message
> "ERROR: CREATE TABLE AS is not allowed in a non-volatile function".

Any chance you're specifying read_only = true to
SPI_execute()/execute_plan()/...?

Greetings,

Andres Freund

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2019-11-13 05:18:03 Re: [PATCH] Do not use StdRdOptions in Access Methods
Previous Message Tom Mercha 2019-11-13 05:09:31 SPI error with non-volatile functions