Re: Naming of new tsvector functions

Поиск
Список
Период
Сортировка
От Stas Kelvich
Тема Re: Naming of new tsvector functions
Дата
Msg-id D91383B7-1CCA-4FE1-8570-C6275C202CC0@postgrespro.ru
обсуждение исходный текст
Ответ на Re: Naming of new tsvector functions  (David Fetter <david@fetter.org>)
Ответы Re: Naming of new tsvector functions  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
> On 03 May 2016, at 00:59, David Fetter <david@fetter.org> wrote:
>
> On Mon, May 02, 2016 at 01:58:11PM -0400, Tom Lane wrote:
>> I wrote:
>>> I think we'd be better off to rename these to tsvector_delete()
>>> and tsvector_filter() while we still can.
>>
>> ... although I now notice that hstore already exposes a function
>> named delete(), so that ship may have sailed already.  But I'm more
>> troubled by filter() anyhow, since that keyword can appear in
>> expressions --- it seems much more likely that that would pose a
>> parsing conflict after future SQL extensions.
>
> I suspect that steering that ship would be a good idea starting with
> deprecation of the old name in 9.6, etc.  hs_filter(), perhaps?
>
> Cheers,
> David.


In 9.5 there already were tsvector functions length(), numnode(), strip()

Recent commit added setweight(), delete(), unnest(), tsvector_to_array(), array_to_tsvector(), filter().

Last bunch can be painlessly renamed, for example to ts_setweight, ts_delete, ts_unnest, ts_filter.

The question is what to do with old ones? Leave them as is? Rename to ts_* and create aliases with deprecation warning?

--
Stas Kelvich
Postgres Professional: http://www.postgrespro.com
Russian Postgres Company




В списке pgsql-hackers по дате отправления:

Предыдущее
От: Stephen Frost
Дата:
Сообщение: Re: pg_dump broken for non-super user
Следующее
От: Robert Haas
Дата:
Сообщение: Re: pg_dump broken for non-super user