Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: newbie index question

Re: newbie index question

From: Buck Turgidson <remove-me_jc_va_at_hotmail.com>
Date: Sun, 18 Feb 2001 12:02:22 GMT
Message-ID: <iROj6.1756$Yl1.130256@bgtnsc06-news.ops.worldnet.att.net>

Hi Jonathan. Could index compression reduce the amount of rows, or is that a logical, not physical construct?

Best regards.

"Jonathan Lewis" <jonathan_at_jlcomp.demon.co.uk> wrote in message news:982225999.12720.1.nnrp-08.9e984b29_at_news.demon.co.uk...
>
> Correct.
>
> If any column in the index is NOT NULL, then every
> row in the table must appear in the index, so your
> count(*) from table will tell you how many rows are
> in the index. In fact, in this case, recent versions
> of Oracle have the option for doing a FAST FULL SCAN
> on the index in order to count the rows in the table.
>
>
> --
> Jonathan Lewis
> Yet another Oracle-related web site: http://www.jlcomp.demon.co.uk
>
> Practical Oracle 8i: Building Efficient Databases
> Publishers: Addison-Wesley
>
> Reviews at: http://www.jlcomp.demon.co.uk/book_rev.html
>
>
>
> Phillip wrote in message <3A8B0E1E.F2B02F22_at_wholefoods.com>...
> >If I have an index on multiple columns, one of which is has a not null
> >constraint, can I find out how many rows are in the index by simply
> >doing a select count(*) on the table? My thinking is that since the
> >column doesn't allow nulls, finding out how many rows in the table will
> >tell me how many rows are in the index. Please advise...
> >
> >--
> >Phillip
> >
>
>
Received on Sun Feb 18 2001 - 06:02:22 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US