pgsql: Improve make_tsvector() to handle empty input, and simplify its

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Improve make_tsvector() to handle empty input, and simplify its
Date: 2017-07-18 17:13:54
Message-ID: E1dXW4I-0005wi-NE@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Improve make_tsvector() to handle empty input, and simplify its callers.

It seemed a bit silly that each caller of make_tsvector() was laboriously
special-casing the situation where no lexemes were found, when it would
be easy and much more bullet-proof to make make_tsvector() handle that.

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/04a2c7f412d01da8100de79b13df4fd39e15ce25

Modified Files
--------------
src/backend/tsearch/to_tsany.c | 58 ++++++++++++-------------------------
src/backend/utils/adt/tsvector_op.c | 31 ++++++--------------
2 files changed, 28 insertions(+), 61 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2017-07-19 16:59:35 pgsql: Doc: add missing note about permissions needed to change log_loc
Previous Message Tom Lane 2017-07-18 16:46:02 pgsql: Fix serious performance problems in json(b) to_tsvector().