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: why db block gets = 0?

Re: why db block gets = 0?

From: <ctcgag_at_hotmail.com>
Date: 19 Oct 2004 21:02:44 GMT
Message-ID: <20041019170244.225$tg@newsreader.com>


niy38_at_hotmail.com (Niy) wrote:
> 9.2.0.5 version
>
> when I connect as hr and turn trace on:
> select * from regions;
>
> output:
>
> ......
>
> Execution Plan
> ----------------------------------------------------------
> 0 SELECT STATEMENT Optimizer=CHOOSE (Cost=2 Card=4 Bytes=56)
> 1 0 TABLE ACCESS (FULL) OF 'REGIONS' (Cost=2 Card=4 Bytes=56)
>
> Statistics
> ----------------------------------------------------------
> 0 recursive calls
> 0 db block gets
> 4 consistent gets
> 0 physical reads
> 0 redo size
> 534 bytes sent via SQL*Net to client
> 499 bytes received via SQL*Net from client
> 2 SQL*Net roundtrips to/from client
> 0 sorts (memory)
> 0 sorts (disk)
> 4 rows processed
>
> If it's first time I can see physical reads not equal to 0.
>
> My confusion is:
> 1) I never update regions tables, why there is consistents gets?

Because the session asks for block XYZ consistent as of ABC. That is what a consistent get is. Now, it just so happens that the only copy of XYZ in the cache might already be consistent as of ABC, but Oracle can hardly know that fact until after it investigates the matter, can it?

> 2) why db block gets is 0 ? it should have some value because
> I'm reading blocks in current mode.

No, your select isn't getting the block in current mode. That is what updates do.

Xho

-- 
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service                        $9.95/Month 30GB
Received on Tue Oct 19 2004 - 16:02:44 CDT

Original text of this message

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