Re: The wonder of increasing rows

From: Mladen Gogala <gogala.mladen_at_gmail.com>
Date: Mon, 28 Oct 2019 08:08:04 -0400
Message-ID: <3fff0199-a087-37e5-f89c-d46c816c311e_at_gmail.com>



Hi Lothar!

If you check DBA_INDEXES view, you will see DISTINCT_KEYS and NUM_ROWS columns. NUM_ROWS is cardinality. Note that if the underlying columns are not defined as NOT NULL,  the index cardinality doesn't necessarily match the table cardinality. DBA_TABLES also has NUM_ROWS column.

Regards

On 10/28/19 7:17 AM, l.flatz_at_bluewin.ch wrote:
> Hi Saysan,
>
> what kind of Index statistics would be used to calculate cardinaliy?
>
> Regards
>
> Lothar
>
> ----Ursprüngliche Nachricht----
> Von : xt.and.r_at_gmail.com
> Datum : 28/10/2019 - 12:04 (MN)
> An : l.flatz_at_bluewin.ch
> Cc : oracle-l_at_freelists.org
> Betreff : Re: The wonder of increasing rows
>
> Hi Lothar,
>
> For index access row-sources (rows 3-4 of the first plan) CBO
> calculates cardinality using index statistics, and for table
> access it uses table statistics.
>
> --
> Best regards,
> Sayan Malakshinov
> Oracle performance tuning engineer
> Oracle ACE Associate
> http://orasql.org
>
>

-- 
Mladen Gogala
Database Consultant
Tel: (347) 321-1217


--
http://www.freelists.org/webpage/oracle-l
Received on Mon Oct 28 2019 - 13:08:04 CET

Original text of this message