Tips

TIPS:

1)

there are three types of read WAIT events - yes: a) db file sequential read (single block IO). this reads into the buffer cache, you do a logical IO after this read to get the block out. b) db file scattered read (multi-block IO, we scatter the blocks in the buffer cache). this reads into the buffer cache, you do logical IO's after this read to get the blocks out. c) direct path read (usually, but not always, done with parallel queries - can be done with serial queries these days as well). this read bypasses the buffer cache, we read from disk directly into your pga avoiding the overhead of the buffer cache. there are two types of reads: a) single block IO b) multi block IO


1) we use db file scattered reads when we know we are going to read more than one block. we use db file sequential reads when we know we are going to read only one block. 

I'm not really sure how to "compare" them other than we use them in different places, under entirely different circumstances. 


If we were decided whether to use sequential versus scattered reads given the same circumstances - it would make sense - however, since the code is like: 

if (blocks to read = 1) 
then 
   read that single block
   add time to the wait event db file sequential read
elsif (blocks to read > 1 ) 
then
   read those blocks
   add time to the wait even db file scattered read
end if;

========================================================================

Comments