3 ms·
> On the other hand count(1) takes an argument and PostgreSQL has to check at every row to see that ts argument, 1, is indeed still not NULL. I expect that's t
by orf 10y ago
> On the other hand count(1) takes an argument and PostgreSQL has to check at every row to see that ts argument, 1, is indeed still not NULL.
I expect that's the same for all function calls like this? Surely pg has a concept of constants and doesn't needlessly re-check parameters?
- DonPellegrino 10y agoIt checks that the first column of each row is not null, that's what the '1' stands for.