SQLite3 and lastrowid
Alexander Gattin
xrgtn at umc.com.ua
Fri Nov 19 07:00:44 EST 2010
Hello,
On Fri, Nov 19, 2010 at 12:32:19PM +0100, Alain
Ketterlin wrote:
> Alexander Gattin <xrgtn at 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
More information about the Python-list
mailing list