Home » SQL & PL/SQL » SQL & PL/SQL » buffers cleaning (Oracle10g)
buffers cleaning [message #319438] Sun, 11 May 2008 05:42 Go to next message
weekend79
Messages: 188
Registered: April 2005
Location: Islamabad
Senior Member

Every one of us knows that every query work relatively slow 1st time then work faster next time as its date block stores in buffers and so is its explain plan etc.

I have to test the performance of my query in my development environment so I want to clean all buffers block and explain plan and so on, before I run my query every time to note the 1st time run performance every time.

Can anyone tell me “how and which” buffers I have to clean for this goal?

Wishes

Re: buffers cleaning [message #319443 is a reply to message #319438] Sun, 11 May 2008 06:07 Go to previous messageGo to next message
Michel Cadot
Messages: 64119
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Simples way: restart the database.
Other way: alter system flush shared_pool or buffer_cache

This is the direct answer but of course this will not give you anything about the performances on production.

Regards
Michel
Re: buffers cleaning [message #319457 is a reply to message #319443] Sun, 11 May 2008 10:02 Go to previous message
William Robertson
Messages: 1640
Registered: August 2003
Location: London, UK
Senior Member
Even restarting the database might not reset things exactly as they were, since the disk array may have its own cache.
Previous Topic: Package
Next Topic: Understanding Document [PL/SQL]
Goto Forum:
  


Current Time: Tue Dec 06 08:41:18 CST 2016

Total time taken to generate the page: 0.10440 seconds