Re: [HACKERS] [GENERAL] workaround for lack of REPLACE() function

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] [GENERAL] workaround for lack of REPLACE() function
Дата
Msg-id 5538.1029306222@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] [GENERAL] workaround for lack of REPLACE() function  (Joe Conway <mail@joeconway.com>)
Список pgsql-patches
Joe Conway <mail@joeconway.com> writes:
> The only remaining problem is that this causes opr_sanity to fail based
> on this query: ...
> This fails because I implemented text_substr() and bytea_substr() to
> take either 2 or 3 args. This was necessary for SQL92 spec compliance.

Rather than loosening the opr_sanity test, I'd suggest setting this
up as two separate builtin functions.  They can call a common
implementation routine if you like.  But a runtime test on the number
of arguments doesn't offer any attractive improvement.

> I'm planning to take on the replace function next.

Isn't Gavin on that already?

            regards, tom lane

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

Предыдущее
От: Joe Conway
Дата:
Сообщение: Re: [HACKERS] [GENERAL] workaround for lack of REPLACE() function
Следующее
От: Joe Conway
Дата:
Сообщение: Re: [HACKERS] [GENERAL] workaround for lack of REPLACE() function