[feature request] ts_headline should have an option to highlight only full matches of <-> expressions
В списке pgsql-hackers по дате отправления:
| От | Jake North |
|---|---|
| Тема | [feature request] ts_headline should have an option to highlight only full matches of <-> expressions |
| Дата | |
| Msg-id | MsulbjG--3-2@tuta.io обсуждение исходный текст |
| Ответы |
Re: [feature request] ts_headline should have an option to highlight only full matches of <-> expressions
|
| Список | pgsql-hackers |
Hi,
I am using Postgres' full text search since some time now and overall it's working really well for me. However one
issueI have is that ts_headline highlights partial matches of FOLLOWED BY (<->) expressions, e.g.
SELECT ts_headline('some words and some more words', to_tsquery('some<->words'));
gives
<b>some</b> <b>words</b> and <b>some</b> more <b>words</b>
while I expect
<b>some words</b> and some more words
I think the highlights of partial matches is in most cases not useful and confusing to end users, they may think the
searchdid not recognize they requested the words to be consecutive. Google also does not highlight partial matches it
seems.
I suspect to implement this would require substantial changes to ts_headline since it seems to treat the lexemes
independently,but it would be a big improvement and should be the default behaviour.
Best regards,
Jake N
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера