pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Thomas Butz <tbutz@optitool.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-bugs@postgresql.org
Subject: Re: Autovacuum analyze can't find C based function
Date: Thu, 19 Jul 2018 10:29:27 +0200 (CEST)
Message-ID: <2003798392.33.1531988965573.JavaMail.tbutz@BART> (raw)
In-Reply-To: <8572.1531922146@sss.pgh.pa.us>
References: <2118571382.49.1531905290326.JavaMail.tbutz@BART>
	<8572.1531922146@sss.pgh.pa.us>

Tom Lane <tgl@sss.pgh.pa.us> writes:
> In recent PG releases, autovacuum executes stuff under a restrictive
> search_path setting (just pg_catalog, in fact).

This should probably be added to section 24.1. of the documentation. At least i couldn't find it elsewhere.

> So you need to do something explicit to reference stuff in other schemas; either schema
> qualify the name

That solved my problem. Now the autovacuum daemon is able to find the function.

> or add a "SET search_path" clause to the function
>definition.

Could you elaborate a bit more on this? It seems like this would only limit/change which objects should be accessed
within the function as described by the CREATE FUNCTION documentation. The function itself wouldn't still be picked
up by the autovacuum daemon or am i missing something?

> This is good practice anyway: what you're seeing is that this
> function fails with any search_path other than the one you use by default.
> 
> 			regards, tom lane


-- 
Best regards


Thomas Butz




view thread (4+ messages)  latest in thread

Message-ID: <2003798392.33.1531988965573.JavaMail.tbutz@BART>
Permalink:  ../2003798392.33.1531988965573.JavaMail.tbutz@BART/
Also on:    postgresql.org/message-id/2003798392.33.1531988965573.JavaMail.tbutz@BART

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: tbutz@optitool.de, tgl@sss.pgh.pa.us
  Subject: Re: Autovacuum analyze can't find C based function
  In-Reply-To: <2003798392.33.1531988965573.JavaMail.tbutz@BART>
  References: <2118571382.49.1531905290326.JavaMail.tbutz@BART> <8572.1531922146@sss.pgh.pa.us> <2003798392.33.1531988965573.JavaMail.tbutz@BART>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox