Hello,

On Fri, Nov 19, 2010 at 12:32:19PM +0100, Alain
Ketterlin wrote:
> Alexander Gattin <xr...@yandex.ru> writes:
> > It's better to select count(1) instead of
> > count(*). The latter may skip rows consisting
> > entirely of NULLs IIRC.
> 
> Wrong: count(anyname) ignores NULL, whereas count(*) does not.

I'm using count(1), which is a count over constant
non-NULL expression (1). It doesn't ignore NULLs
or duplicate rows, as my attempts with Oracle 10g,
8g and sqlite3 show.

-- 
With best regards,
xrgtn
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to