Should there be a charcat?

Поиск
Список
Период
Сортировка
От Jim C. Nasby
Тема Should there be a charcat?
Дата
Msg-id 20061006192826.GV72517@nasby.net
обсуждение исходный текст
Ответы Re: Should there be a charcat?  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Column |     Type      | Modifiers
--------+---------------+-----------c      | character(20) |

decibel=# select c, c || ('x'::char) from c;         c           | ?column?
----------------------+----------x                    | xx

I would think that c || 'x' would result in 'x                    x', but it doesn't because the only text
concatenationfunction we have is textcat(text,
 
text). As soon as you cast a char to text, you lose all the trailing spaces.

Is this what the spec says should happen?
-- 
Jim Nasby                                            jim@nasby.net
EnterpriseDB      http://enterprisedb.com      512.569.9461 (cell)


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

Предыдущее
От: Oleg Bartunov
Дата:
Сообщение: Re: Backbranch releases
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Should there be a charcat?