Re: Boolean internal representation

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: Boolean internal representation
Дата
Msg-id 20020919004526.GA21448@svana.org
обсуждение исходный текст
Ответ на Re: Boolean internal representation  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-general
On Wed, Sep 18, 2002 at 08:33:04PM -0400, Bruce Momjian wrote:
> Garo Hussenjian wrote:
> > Is there a way to always return booleans as 1/0 instead of t/f, without
> > using a CASE statement...
>
> How do you feel about a plpgsql function that does it:
>
>     SELECT print01(boolcol) FROM ...

Interestinly, if you use Perl DBI, it translates t/f to 1/0 for you. Very
annoying if you're not expecting it to :)
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> There are 10 kinds of people in the world, those that can do binary
> arithmetic and those that can't.

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Boolean internal representation
Следующее
От: "Marc G. Fournier"
Дата:
Сообщение: Re: [HACKERS] PGXLOG variable worthwhile?