pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Bruce Momjian <bruce@momjian.us>
To: Pavel Borisov <pashkin.elfe@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Alex Malek <magicagent@gmail.com>
Cc: pgsql-bugs@lists.postgresql.org
Cc: ngigi@at.co.ke
Subject: Re: BUG #15172: Postgresql ts_headline with <-> operator does not highlight text properly
Date: Sat, 28 Oct 2023 19:39:56 -0400
Message-ID: <ZT2bzCEZ1UgpAe7a@momjian.us> (raw)
In-Reply-To: <CALT9ZEGMS_U-dLQLROg5op9va7kjA8qQMRKbUROSWsv2sYec5w@mail.gmail.com>
References: <152461454026.19805.6310947081647212894@wrigleys.postgresql.org>
	<CAGH8cccS-9yb1VkgUTAaghz4P3aL8DneH_24bN7Y0LCLO8by1Q@mail.gmail.com>
	<ZT1kGIbiALGclTUA@momjian.us>
	<1995601.1698526000@sss.pgh.pa.us>
	<CALT9ZEGMS_U-dLQLROg5op9va7kjA8qQMRKbUROSWsv2sYec5w@mail.gmail.com>

On Sun, Oct 29, 2023 at 01:20:11AM +0400, Pavel Borisov wrote:
> Hi, Bruce and Tom!
> I think that the ts_headline main functionality is to make Postgres
> more friendly to search-engine-like approach, which I feel is too
> niche usage scenario for supporting it as a part of core code. If
> remember right, bug reports coming from the users supposing it has
> more strict semantics than it has in reality are regular. And I also
> remember myself being puzzled by unusual output in the past.
> 
> If we fiddle with other parameters of ts_headline we can easily have
> other kinds of output that seem counterintuitive e.g.:
> SELECT ts_headline('English',

I just posted a proposed doc patch which should help reduce the number
of people surprised by the highlighting.  Let's see if that helps.

FYI, here is a Stack Overflow post from 2021 linking to the original
email that started this thread from 2018:

	https://stackoverflow.com/questions/69512416/is-ts-headline-intended-to-highlight-non-matching-parts...

-- 
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EDB                                      https://enterprisedb.com

  Only you can decide what is important to you.





view thread (13+ messages)  latest in thread

Message-ID: <ZT2bzCEZ1UgpAe7a@momjian.us>
Permalink:  ../ZT2bzCEZ1UgpAe7a@momjian.us/
Also on:    postgresql.org/message-id/ZT2bzCEZ1UgpAe7a@momjian.us

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-bugs@postgresql.org
  Cc: bruce@momjian.us, pashkin.elfe@gmail.com, tgl@sss.pgh.pa.us, magicagent@gmail.com, pgsql-bugs@lists.postgresql.org, ngigi@at.co.ke
  Subject: Re: BUG #15172: Postgresql ts_headline with <-> operator does not highlight text properly
  In-Reply-To: <ZT2bzCEZ1UgpAe7a@momjian.us>

* 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