Re: about type cast

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: about type cast
Дата
Msg-id 20437.1328548081@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: about type cast  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> 2012/2/6 zoulx1982 <zoulx1982@163.com>:
>> my question is why int can cast to bit , but bot for bit varying?

> Off the top of my head, I'm guessing that it's just a case of nobody
> having implemented it.

I have some vague recollection that we didn't want to be squishy about
the length of the resulting bitstring.  When you cast to bit you're more
or less forced to specify what you want, since the spec-mandated default
length is only 1.  varbit would leave us having to make a decision in
the code.

Anyway, try searching the pgsql-hackers archives if you want some
history.
        regards, tom lane


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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: about type cast
Следующее
От: Andrew Dunstan
Дата:
Сообщение: Re: [GENERAL] pg_dump -s dumps data?!