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: Ideas to workaround view merge being disabled (try #2)

RE: Ideas to workaround view merge being disabled (try #2)

From: Jesse, Rich <Rich.Jesse_at_qtiworld.com>
Date: Thu, 08 Jan 2004 09:19:42 -0800
Message-ID: <F001.005DC290.20040108091942@fatcity.com>


And, sorry, Raj, it's apparently *any* function in the view that can cause the FTS. I should have mentioned that...<blush>

Rich

Rich Jesse                           System/Database Administrator
rjesse_at_qtiworld.com                  Quad/Tech Inc, Sussex, WI USA


-----Original Message-----
Sent: Thursday, January 08, 2004 11:09 AM To: Multiple recipients of list ORACLE-L

<sigh> stupid KVM hacking my mouse gets me again. Here's the *whole* message:

Hey all,

So, there I am on 8.1.7.4.0 creating some SQL suitable for a view:

SELECT

TS.username, 
TS.reportdate, 
TS.hours AS hours, 

DECODE(TD.description, NULL, SC.DESCRIPTION, TD.DESCRIPTION) AS TASK_DESCRIPTION,
TEAM.teamtype AS TeamType,
TS.productline,
ST.SUBTASKID "DEFECTID",
ST.DESCRIPTION "DEFECT_DESCRIPTION"

FROM
T1 TS,
T2 ST,
T3 TD, 
TEAM , 

T5 SC
WHERE
TS.TASKID = TD.TASKID (+) AND 
TS.TEAMID = TEAM.TEAMID AND 
TS.WORKORDERNO = SC.WORKORDERNO (+) 

AND TS.operation = SC.OPERATIONNO (+)
AND TS.TASKID = ST.TASKID (+); Works great, except when the view is created from this SQL because according to Metalink article 1030221.6, the DECODE function is preventing the view from being merged, causing an FTS on the T5 (SC) table. Of course, this table is near 1M rows and gets caught in an inner NL in the explain plan
(cutting/pasting the explain plan doesn't seem to want to work in Windohs).

The doc says the workaround is to move the DECODE outside the view. This won't work for us as the end-user is <sigh> MS Access. Anyone have an idea other than a RULE hint to get around this?

TIA,
Rich

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Jesse, Rich
  INET: Rich.Jesse_at_qtiworld.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).
Received on Thu Jan 08 2004 - 11:19:42 CST

Original text of this message

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