| От | Tom Lane |
|---|---|
| Тема | Re: Problem inserting data |
| Дата | |
| Msg-id | 17755.1213973846@sss.pgh.pa.us обсуждение |
| Ответ на | Re: Problem inserting data (Adrian Klaver <aklaver@comcast.net>) |
| Список | pgsql-sql |
Adrian Klaver <aklaver@comcast.net> writes: > Two options: > 1) Change the column in Postgres to an integer type. > 2) Change the assignment in pg_cast from explicit to implied for the > int4,bool cast. See for more details: > http://www.postgresql.org/docs/8.3/interactive/catalog-pg-cast.html Making it an assignment cast would be sufficient for the particular case shown, and would be less likely to introduce surprising behavior elsewhere. Of course, depending on how thoroughly the application confuses int and bool, you might be stuck with using the implicit cast. But it's a bit scary. I think I'd look at option (1) before trying (2) with an implicit cast. regards, tom lane
В списке pgsql-sql по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера