BUG #9541: Result of TRIM function has changed

Поиск
Список
Период
Сортировка
От uehara.kazuki@po.ntts.co.jp
Тема BUG #9541: Result of TRIM function has changed
Дата
Msg-id 20140312093753.335.3227@wrigleys.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #9541: Result of TRIM function has changed  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      9541
Logged by:          Kazuki Uehara
Email address:      uehara.kazuki@po.ntts.co.jp
PostgreSQL version: 9.3.3
Operating system:   CentOS release 5.6
Description:

Depending on the version, the result of the TRIM function is different.

I did the following steps.

1. Change the setting of search_path.
---------------------------------------------
search_path='test,pg_catalog,"$user",public'
---------------------------------------------

2. Run the following query.
-------------------------------------------
CREATE FUNCTION LTRIM(CHAR,text)
RETURNS text
AS 'ltrim'
LANGUAGE internal
STRICT;
SELECT '|' || TRIM(LEADING 'a' FROM 'abcd'::char(7)) || '|';
--------------------------------------------


Execution result of each version

PostgreSQL9.3.1
| postgres=# SELECT '|' || TRIM(LEADING 'a' FROM 'abcd'::char(7)) || '|';
|  ?column?
| ----------
|  |bcd|
| (1 row)

PostgreSQL9.3.2:
| postgres=# SELECT '|' || TRIM(LEADING 'a' FROM 'abcd'::char(7)) || '|';
|  ?column?
| ----------
|  |bcd|
| (1 row)

PostgreSQL9.3.3:
| postgres=# SELECT '|' || TRIM(LEADING 'a' FROM 'abcd'::char(7)) || '|';
|  ?column?
| ----------
|  |bcd   |
| (1 row)


Thank you very much.

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

Предыдущее
От: Lekshmi Ts
Дата:
Сообщение: postgres 8.2.13 compatibility with RHEL 6.4
Следующее
От: prasanna@semantifi.com
Дата:
Сообщение: BUG #9547: Unable install postgres on AIX 5.3