Re: Options for poorly performing SQL

From: Job Miller <>
Date: Mon, 4 Feb 2013 14:39:33 -0800 (PST)
Message-ID: <>

You don't say whether this is a bad SQL statement or a bad plan from a SQL statement. If you rewrote the SQL to get the same result set smarter, that's different than you re-writing the statement so that the same statement is optimized better and gets a better plan.

bad plans can be fixed with profiles, but bad SQL with a good plan can only be fixed with a query rewrite or a materialized view/query-rewrite technique to make the bad sql more efficient.


 From: "Coll-Barth, Michael" <> To:; oracle-l <> Sent: Monday, February 4, 2013 10:24 AM
Subject: RE: Options for poorly performing SQL  

> -----Original Message-----
> From: Sandra Becker

[mcb >]
> Oracle - EE
> OS - SUSE11

> They refuse to even look at the statement because
> it is dynamically created in the application using javaScript.  Not
> javaScript, I'm not sure why it makes a difference.  Perhaps other
> dynamically created statements would benefit from changes here as

I suspect that what they are doing is building the SQL code based on choices that are being made on a web site.  I've done enough of those. What I did to greatly improve performance was to build a proc and then call it with passed parms.  Even without the proc, just using bind variables will improve response time.


Received on Mon Feb 04 2013 - 23:39:33 CET

Original text of this message