| От | TJ O'Donnell |
|---|---|
| Тема | Re: problem with bit(n) type |
| Дата | |
| Msg-id | 434D0DCB.3010808@acm.org обсуждение исходный текст |
| Ответ на | problem with bit(n) type (Sergey Karin <sergey.karin@gmail.com>) |
| Список | pgsql-general |
Binary data in bit(n) has no text equivalent, and so cannot be "cast" as text. It has an "external representation", e.g. B'10010101', but this is not the same as a cast. In some cases, where there bit(n) has (n mod 8) = 0 and the bitstring happens to be valid ascii in the text range, one could say there is a text equivalent, but in general not. I think you're looking for some kind of printf-type %b function? Maybe someone has written one, or maybe you'll have to do so. If you do, how about a hex representation of bit(n) - I could use that ;) TJ O'Donnell http://www.gnova.com/ ----- But this is the big problem for me... Is there a way to cast bit(n) to text or varchar? thanks in advance. Sergey Karin
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера