Home » RDBMS Server » Server Administration » buffer cache (DML)
buffer cache (DML) [message #386226] Fri, 13 February 2009 03:26 Go to next message
tjay
Messages: 37
Registered: September 2008
Member
Hi

User1:

update test set a=1 where b=2;

User2:
select * from test


When the user1 issues update statement and do not perfom commit;

undo is generated, and this undo block is stored in buffercache.

Interms of read consistency, user2 will scan the buffercache and find undoblock in buffercache and read the data from there.

Is it correct?There is no need to go to disk..
Re: buffer cache (DML) [message #386235 is a reply to message #386226] Fri, 13 February 2009 03:49 Go to previous messageGo to next message
Michel Cadot
Messages: 64127
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
The undo block may be flushed onto the disk.
For Oracle buffer cache, there is no difference between data and undo blocks.

Regards
Michel
Re: buffer cache (DML) [message #386239 is a reply to message #386235] Fri, 13 February 2009 04:27 Go to previous messageGo to next message
tjay
Messages: 37
Registered: September 2008
Member
1-)
Inorder to provide read consistency,
oracle always first looks at the buffer cache to read from the undo block and if itis not found, it will go disk.
Right?

2-)
Which background process is responsible for scanning the buffer cache?
Re: buffer cache (DML) [message #386254 is a reply to message #386239] Fri, 13 February 2009 06:01 Go to previous messageGo to next message
Michel Cadot
Messages: 64127
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
1) Yes.
2) If you mean when you execute a query, your server (shadow) process not a background one

Regards
Michel
Re: buffer cache (DML) [message #386334 is a reply to message #386254] Fri, 13 February 2009 17:20 Go to previous messageGo to next message
tjay
Messages: 37
Registered: September 2008
Member
Ummmmmm

So,When a user issues a DML statement for example insert;
Oracle first looks buffercache for the necessary block;
If it is not in buffercache, it retrieves the block from disk and places a copy cache and make the insert inside the buffercache and so on

Is it correct?
Re: buffer cache (DML) [message #386363 is a reply to message #386334] Sat, 14 February 2009 00:21 Go to previous message
Michel Cadot
Messages: 64127
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Not in the details but roughly, yes.

I recommend you to read Database Concepts.

Regards
Michel
Previous Topic: Software installation
Next Topic: ORA-01555
Goto Forum:
  


Current Time: Wed Dec 07 06:46:32 CST 2016

Total time taken to generate the page: 0.15738 seconds