Search Postgresql Archives

Re: select count(*);

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11 June 2015 at 15:35, Yves Dorfsman <yves@xxxxxxxxx> wrote:
On 2015-06-11 08:20, Geoff Winkless wrote:
> On 11 June 2015 at 15:17, Marc Mamin <M.Mamin@xxxxxxxxxxxx
> <mailto:M.Mamin@xxxxxxxxxxxx>>wrote:
>
>     >But COUNT(*)
>     >
>     >does have meaning - it means "the number of rows".
>
>     which rows? :-)
>
>
> ​The number of rows in the query, as well you know :)

But interestingly

    postgres=# select count(*) where 1=0;
     count
    -------
         0
    (1 row)


​As expected.

=#
SELECT
 1 WHERE 1=0;
 ?column?
----------
(0 rows)

​Geoff​


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux