Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: Wrong results from SQL in 8174
Could that be the "common subquery elimination" optimization bug?
I believe it was supposed to be fixed in 8.1.7.4.
Try setting optimizer_features_enabled=8.1.6 and see if that makes a
difference.
At 02:20 PM 5/5/2004, you wrote:
>Seems to be the day for SQL bugs. A developer here was running a 3 table join.
>Part of the WHERE clause was a BETWEEN statement. When he increased the
>range of
>the BETWEEN, the number of records returned by the query dropped. I ran a
>sql_trace/tkprof to compare explain plans and row counts. Execution path
>changed
>(increasing the range in the BETWEEN increased the expected # of rows returned
>from the table. Thus the new plan.). The row counts in the problem
>execution-plan made no sense to me. I tried running both SQL's with an ORDERED
>hint to force the same execution plan. Both result sets were now the same.
>Definitely a SQL bug.
>
>So now I'm having developers ask "what assurance do we have that the
>numbers we
>are reporting in any report are correct?" I'm still trying to track down the
>root cause of this bug. Anyone else seen it? SQL and explain plans follows.
Wolfgang Breitling
Oracle7, 8, 8i, 9i OCP DBA
Centrex Consulting Corporation
http://www.centrexcc.com
-- Archives are at http://www.freelists.org/archives/oracle-l/ FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html -----------------------------------------------------------------Received on Wed May 05 2004 - 16:15:09 CDT