Re: hstore or jsonb ?
Laurenz Albe <laurenz.albe@cybertec.at>
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Bzzzz <lazyvirus@gmx.com>, pgsql-novice@lists.postgresql.org
Date: 2022-11-15T07:05:31Z
Lists: pgsql-novice
On Mon, 2022-11-14 at 22:21 +0100, Bzzzz wrote:
> That depends on the query you need to support.
> >
> > I have no idea what you mean by "fulltext accurate search" in a hstore
> > or JSON.
>
> One kind, that will be something like :
> SELECT websearch_to_tsquery('english', 'switching power supply
> output tension 5 Vcc 5 A') ;
Indexing full text search is simple.
If the query is
... WHERE <someexpression> @@ <somequery>
the index is to be
CREATE INDEX ON tab USING gin ((<someexpression>));
Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com