Re: 0/1 vs true/false
От | Peter Eisentraut |
---|---|
Тема | Re: 0/1 vs true/false |
Дата | |
Msg-id | Pine.LNX.4.56.0307231714090.1649@krusty.credativ.de обсуждение исходный текст |
Ответ на | Re: 0/1 vs true/false (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-general |
Tom Lane writes: > Note that the spec only really speaks to the question of what booleans > look like when written as constants in SQL statements. AFAICT it does > not take a position on what representations are to be used when > transferring data into or out of the database. So using '0' or '1' as > input to a boolean field is not contrary to spec, but merely outside > the spec (and in fact we will accept those strings for boolean...) The transfer into the database is regulated when you write the data into the SQL statement (as you normally would). Input through prepare/bind and input is governed by the respective client interface (e.g., embedded SQL language bindings, JDBC spec, ODBC spec). If you use libpq or psql then you're beyond all standards anyway. -- Peter Eisentraut peter_e@gmx.net
В списке pgsql-general по дате отправления: