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: WHERE 1 = 1 (any info on this)

Re: WHERE 1 = 1 (any info on this)

From: Nuno Souto <nsouto_at_optusnet.com.au>
Date: Tue, 21 Oct 2003 04:45:02 -0800
Message-ID: <F001.005D3DBF.20031021044502@fatcity.com>


AFAIK, it has two origins:

1- To make editing text sql scripts easier, in terms of alignment between the predicates.

2- As a trick to enhance the WHERE clause in blocks in Forms, very old versions.

Other than that never heard it made the slightest difference to the CBO.
Cheers
Nuno Souto
nsouto_at_optusnet.com.au
----- Original Message -----
>
> "the 1=1 is in there to avoid doing repetitive index scans for single
> rowids, when the app "knows" the result set is going to be manipulated
> rowid's for a large subset of the table. I would guess your DUAL/CBO example
> had some similar effect."
>
> Is anyone familiar enough with this tweak to explain it ?
>

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Nuno Souto
  INET: nsouto_at_optusnet.com.au

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 Tue Oct 21 2003 - 07:45:02 CDT

Original text of this message

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