Home » SQL & PL/SQL » SQL & PL/SQL » Query is extremely slow (URGENT HELP NEEDED)
icon8.gif  Query is extremely slow (URGENT HELP NEEDED) [message #184252] Tue, 25 July 2006 22:23 Go to next message
rebeccaz
Messages: 18
Registered: August 2005
Junior Member
Hi,

Same SQL is executed in 2 database having same set of data but different environment. But the response for 1 was around 5secs or less while the other was like 105 secs. What could have caused this vast difference?

Rdgs,

Re: Query is extremely slow (URGENT HELP NEEDED) [message #184279 is a reply to message #184252] Wed, 26 July 2006 00:37 Go to previous messageGo to next message
Frank
Messages: 7880
Registered: March 2000
Senior Member
Could be a number of reasons.
Did you collect statistics?
icon7.gif  Re: Query is extremely slow (URGENT HELP NEEDED) [message #184294 is a reply to message #184252] Wed, 26 July 2006 01:17 Go to previous messageGo to next message
rebeccaz
Messages: 18
Registered: August 2005
Junior Member
I am not the dba and I do not have the rights. What statistics should I collect? Can you share the possible reasons you have in mind?

Thanks & Rdgs,
Re: Query is extremely slow (URGENT HELP NEEDED) [message #184300 is a reply to message #184294] Wed, 26 July 2006 01:41 Go to previous messageGo to next message
Maaher
Messages: 7062
Registered: December 2001
Senior Member
A couple of questions:
  1. Are fast_db and slow_db on the same machine?
  2. Are fast_db and slow_db of the same version?
  3. Do fast_db and slow_db have the same amount of data?
  4. Do fast_db and slow_db have the same indexes?
  5. Are the table statistics in both databases up to date? If you're not sure, check out the package DBMS_STATS.
  6. Is the load on fast_db and slow_db the same? Are the same number of users connected to both databases?


MHE
Re: Query is extremely slow (URGENT HELP NEEDED) [message #184327 is a reply to message #184300] Wed, 26 July 2006 03:01 Go to previous message
JRowbottom
Messages: 5933
Registered: June 2006
Location: Sunny North Yorkshire, ho...
Senior Member
Also:

7. Do Fast_Db and Slow_db have the same settings in v$parameter
Previous Topic: Find values in other records of a table
Next Topic: getting table of ref while inserting data
Goto Forum:
  


Current Time: Tue Dec 06 16:20:25 CST 2016

Total time taken to generate the page: 0.11362 seconds