Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Purely for your amusement

RE: Purely for your amusement

From: Niall Litchfield <n-litchfield_at_audit-commission.gov.uk>
Date: Fri, 28 Feb 2003 01:38:39 -0800
Message-ID: <F001.0055C9CC.20030228013839@fatcity.com>


As others have pointed out 6 tables, 2 joins does not a happy execution plan make - and it also looks like some of your tables are views to add to the mix.

My diagnosis, this is an ad-hoc query constructed by an end user. To find the source of the problem you'll need to listen carefully, the loudest whine will be coming from the source of the problem. If this turns out to be the CEO, some disgression may be called for.

On the bright side if you save out the sql, then any time someone complains about the ratios you can always run it a few times till performance is better :(.

Niall Litchfield
Oracle DBA
Audit Commission
0117 975 7805

-----Original Message-----
Sent: 27 February 2003 22:51
To: barbarabbaker_at_yahoo.com; ORACLE-L_at_fatcity.com

I found it in our "offending sql statements" report we get from the database each morning. Went looking when someone complained about poor performance. (Ya, do you THINK!!!!) Probably not Discoverer. I think it was either Access or Crystal. (When I found it, it had double quotes around everything, which is usually Access.)

On the bright side, our BHR looks great!!! Guess I'll go home and have a beer.

For Jared's entertainment, here's the sql:

SELECT WO.ACCT_KEY, WO.PUB, WO.ISSUE, WO.STATUS,

WO.AD_TYPE, WO.EDITION, WO.SECTION, WO.AD_DESC,
WO.COMMENTS, WO.JOB_NBR, WO.ACT_SIZE, WO.BASE_AMT,
WO.DISC_TOT,
WO.AGY_COMM, WO.SP_AGY_COMM, WO.INVC_AMT, WO.FREQ, WO.CIRCULATION, WO.RC_NBR, WO.AVG_RATE, NAD.NAM1, NAD.PROD_4, PUB.SLS_EFF_ISS_1, PUB.SLS_NBR_1_1, PUB.SLS_EFF_ISS_2, PUB.SLS_NBR_2_1, PUB.SLS_NBR_3_1, CNR.SLS_NBR_1, WOEMANIFEST_VIEW.WOE_EDITION, WO_CHARG_VIEW.PROD1, WO_CHARG_VIEW.AMT1, WO_CHARG_VIEW.PROD2, WO_CHARG_VIEW.AMT2, WO_CHARG_VIEW.PROD3, WO_CHARG_VIEW.AMT3, WO_CHARG_VIEW.PROD4, WO_CHARG_VIEW.AMT4, WO_CHARG_VIEW.AMT5, WO_CHARG_VIEW.AMT6, WO_CHARG_VIEW.AMT7, WO_CHARG_VIEW.AMT8, WO_CHARG_VIEW.AMT9 FROM ADMARC.WO WO, ADMARC.NAD NAD, ADMARC.PUB PUB, ADMARC.CNR CNR, ADMARC.WOEMANIFEST_VIEW WOEMANIFEST_VIEW, ADMARC.WO_CHARG_VIEW WO_CHARG_VIEW WHERE WO.ACCT_KEY = NAD.ACCT_NBR (+)  AND WO.ACCT_KEY = PUB.ACCT_KEY


Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more http://taxes.yahoo.com/
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Barbara Baker
  INET: barbarabbaker_at_yahoo.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).




**********************************************************************
This email contains information intended for the addressee only.
It may be confidential and may be the subject of legal and/or
professional privilege.  Any dissemination, distribution, copyright
or use of this communication without prior permission of the
sender is strictly prohibited.
**********************************************************************

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Niall Litchfield
  INET: n-litchfield_at_audit-commission.gov.uk

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Fri Feb 28 2003 - 03:38:39 CST

Original text of this message

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