From: Tom Lane <tgl@sss.pgh.pa.us>
To: Mark Kirkwood <markir@paradise.net.nz>
Cc: chris smith <dmagick@gmail.com>
Cc: Jim C. Nasby <jnasby@pervasive.com>
Cc: PostgreSQL Performance <pgsql-performance@postgresql.org>
Subject: Re: Query using SeqScan instead of IndexScan
Date: Sat, 01 Apr 2006 23:46:09 -0500
Message-ID: <18072.1143953169@sss.pgh.pa.us> (raw)
In-Reply-To: <442F53A6.9090707@paradise.net.nz>
References: <2F1712F1-E5E2-455E-A291-06F300A66549@clickspace.com>
<20060331155911.GP49405@pervasive.com>
<EBEB7ACF-84A8-4FCF-A481-8C087FF372D1@clickspace.com>
<3c1395330603311723i368092f2jf0c2291ab033ae2a@mail.gmail.com>
<20060401153247.GI49405@pervasive.com>
<3c1395330604011650r61c793a7td3e8be58ab023c7b@mail.gmail.com>
<3c1395330604011732n4cd523c3gf7c1e4c346630aad@mail.gmail.com>
<442F53A6.9090707@paradise.net.nz>
Mark Kirkwood <markir@paradise.net.nz> writes:
> It is a bit confusing - '(distinct) cardinality' might be a better
> heading for their 'cardinality' column!
The usual mathematical meaning of "cardinality" is "the number of
members in a set". That isn't real helpful for the point at hand,
because the mathematical definition of a set disallows duplicate
members, so if you're dealing with non-unique values you could argue it
either way about whether to count duplicates or not. However, I read in
the SQL99 spec (3.1 Definitions)
d) cardinality (of a value of a collection type): The number of
elements in that value. Those elements need not necessarily have
distinct values.
so ... as all too often ... the mysql boys have not got a clue about
standards compliance. They are using this term in the opposite way
from how the SQL committee uses it.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: tgl@sss.pgh.pa.us, markir@paradise.net.nz, dmagick@gmail.com, jnasby@pervasive.com
Subject: Re: Query using SeqScan instead of IndexScan
In-Reply-To: <18072.1143953169@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox