Re: return true / false instead of int4 value

Поиск
Список
Период
Сортировка
От Doug Fields
Тема Re: return true / false instead of int4 value
Дата
Msg-id 5.1.0.14.2.20020604121814.02c4b1e0@pop.pexicom.com
обсуждение исходный текст
Ответ на return true / false instead of int4 value  ("Johnson, Shaunn" <SJohnson6@bcbsm.com>)
Список pgsql-general
select count(*) from t_table
having count(*) > 1500000
 
[/snip]

But want to return a true/false (bool) result.

Off the top of my head:

select count > 1500000 from (select count(*) as count from t_table) as a;

Doug

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

Предыдущее
От: Stephan Szabo
Дата:
Сообщение: Re: return true / false instead of int4 value
Следующее
От: "Peter Darley"
Дата:
Сообщение: Re: return true / false instead of int4 value