Re: [BUGS] BUG #14693: create materialized view forces btrim

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: [BUGS] BUG #14693: create materialized view forces btrim
Дата
Msg-id CAKFQuwYRsoR8jtb6kw_BRzUNJqo2wkQ_p+xGV=XhTdSHECZHGw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [BUGS] BUG #14693: create materialized view forces btrim  (Ian Boardman <isb0459@gmail.com>)
Ответы Re: [BUGS] BUG #14693: create materialized view forces btrim
Список pgsql-bugs
On Tue, Jun 6, 2017 at 2:40 PM, Ian Boardman <isb0459@gmail.com> wrote:
Thanks very much folks. For your entertainment, this seems to be working. I changed the expression to  trim(from foo) || bar,  in my select statement, and reliably got a non-empty result.

​So does "SELECT 'a non empty value';"...I guess if you're happy, great, but your solution and the original problem look nothing alike.​

  I committed this via "create materialized view", and inspected what Postgres did with it (\dSm+). It still is stored as btrim(foo) || bar; and yet, it works correctly(?!) 

​I don't know why btrim is the canonical spelling of the trim function but, like Tom said, it is.​  The choice of btrim or trim will not influence the end result of the query in any way (though I don't think btrim accepts the "from" keyword that trim does).

David J.

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

Предыдущее
От: Mike Palmiotto
Дата:
Сообщение: Re: [BUGS] BUG #14682: row level security not work with partitioned table
Следующее
От: Tom Lane
Дата:
Сообщение: Re: [BUGS] BUG #14693: create materialized view forces btrim