| От | Thomas Lockhart |
|---|---|
| Тема | Re: Unsigned ints (Help) |
| Дата | |
| Msg-id | 3AC208E4.70B4AF6C@alumni.caltech.edu обсуждение исходный текст |
| Ответ на | Unsigned ints (Adriaan Joubert <a.joubert@albourne.com>) |
| Список | pgsql-hackers |
> At this point I decided that somewhere in the definition of the type
> there must be a way of specifying how values can be transformed. Can
> anybody explain to me what I need to change to make this work? Without
> this ecpg cannot work with unsigned ints, so explicit casting is not an
> option.
The large integer-like value is silently transformed into a float8 by
the scanner (very early in the parsing stage). You have not provided a
function to transform float8 into uint4, which if you do so will fix
your problem. Do a
create function uint4(float8)...
and the type coersion code will understand how to convert one into the
other.
- Thomas
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера