From: Igal @ Lucee.org <igal@lucee.org>
Cc: pgsql-general <pgsql-general@postgresql.org>
Subject: Re: pg_trgm Extension Installed but Operators and Functions do not exist
Date: Sun, 28 Jan 2018 12:49:31 -0800
Message-ID: <6fe73c13-cb22-09ca-bcd8-a11947be71a1@lucee.org> (raw)
In-Reply-To: <14642.1517171732@sss.pgh.pa.us>
References: <fb4da7cb-6e21-cb61-0ddf-97ecc6d8f1a7@lucee.org>
<14642.1517171732@sss.pgh.pa.us>
On 1/28/2018 12:35 PM, Tom Lane wrote:
> "Igal @ Lucee.org" <igal@lucee.org> writes:
>> I am trying to run a query which was working a few weeks ago, and it
>> utilizes the <<-> operator but I am getting an error: operator does not
>> exist text <<-> text.
>>
>> If I try to install the pg_trgm extension with `CREATE EXTENSION
>> pg_trgm;` I get an error: extension "pg_trgm" already exists.
> Seems like a likely bet is that the extension is installed in a schema
> that isn't in your search_path.
Thank you, Tom. I was unaware of the fact that extensions are installed
to specific schemas.
For future users who might face this issue, I fixed it by re-creating
the extension in the pg_catalog schema, which is always in the
search_path [1]:
DROP EXTENSION pg_trgm;
CREATE EXTENSION pg_trgm SCHEMA pg_catalog;
Thanks again,
Igal
[1]
https://www.postgresql.org/docs/current/static/runtime-config-client.html#GUC-SEARCH-PATH
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-general@postgresql.org
Cc: igal@lucee.org
Subject: Re: pg_trgm Extension Installed but Operators and Functions do not exist
In-Reply-To: <6fe73c13-cb22-09ca-bcd8-a11947be71a1@lucee.org>
References: <fb4da7cb-6e21-cb61-0ddf-97ecc6d8f1a7@lucee.org> <14642.1517171732@sss.pgh.pa.us> <6fe73c13-cb22-09ca-bcd8-a11947be71a1@lucee.org>
* 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