Join ORA_ROWSCN problem

Hello

I have problem with ORA_ROWSCN column when I join statement in SQL:

Context:

CREATE TABLE table_source(
  lib varchar(10)
) ROWDEPENDENCIES ;

CREATE TABLE table_target(
  lib varchar(10),
  rowid_src ROWID,
  rowscn_src NUMBER
);

INSERT INTO table_source (lib) VALUES ('a');
INSERT INTO table_source (lib) VALUES ('b');
INSERT INTO table_source (lib) VALUES ('c');
INSERT INTO table_source (lib) VALUES ('d');
commit;

INSERT INTO table_target ( ROWID_SRC, rowscn_src, lib) SELECT ROWID, ORA_ROWSCN, lib  FROM table_source;

select ORA_ROWSCN, lib FROM table_source;

-- ORA_ROWSCN LIB
-- ---------- ----------
-- 5056691355 a    
-- 5056691355 b    
-- 5056691355 c    
-- 5056691355 d

select rowscn_src, lib FROM table_target;

-- ROWSCN_SRC LIB
-- ---------- ----------
-- 5056691355 a    
-- 5056691355 b    
-- 5056691355 c    
-- 5056691355 d  

  update table_source set lib='a1' WHERE lib='a';
  commit;

  select ORA_ROWSCN, lib FROM table_source;

-- ORA_ROWSCN LIB
-- ---------- ----------
-- 5056691393 a1   
-- 5056691355 b    
-- 5056691355 c    
-- 5056691355 d

  select rowscn_src, lib FROM table_target;

-- OWSCN_SRC LIB
-- ---------- ----------
-- 5056691355 a    
-- 5056691355 b    
-- 5056691355 c    
-- 5056691355 d  


OK, let's try to get the lines that have changed:

SELECT src.lib
FROM table_source src
INNER JOIN  table_target target ON src.ROWID = target.rowid_src
WHERE src.ORA_ROWSCN <> target.rowscn_src

-- LIB
----------
-- a1    
-- b     
-- c     
-- d 

---------- EXPECTED:
-- LIB
----------
-- a1    

The problem arises when we JOIN statemement:



select count(*)
FROM table_source src
WHERE src.ORA_ROWSCN = 1;

--   COUNT(*)
-- ----------
--          0
-- OK !



select count(*)
FROM table_source src
JOIN  table_target target ON src.ROWID = target.rowid_src
WHERE src.ORA_ROWSCN = 1;

--   COUNT(*)
-- ----------
--       4
-- EXPECTED: 0 


You can help me find my mistake.

Thank you

When you use the ANSI join syntax and have a question the FIRST thing you can do is to use a standard Oracle syntax.

This seems to be one of the MANY bugs in the functionality of join 11.2.0.1.0 ANSI

I can reproduce the problem by using YOUR code:

SELECT src.lib
FROM table_source CBC
Target INNER JOIN table_target ON CBC. ROWID = target.rowid_src
WHERE the CBC. ORA_ROWSCN <> target.rowscn_src

LIB

A1

b

c

d

But there is no problem if I use the standard join syntax

SELECT src.lib
Table_source CBC, table_target target
where src. ROWID = target.rowid_src
and
CBC. ORA_ROWSCN <> target.rowscn_src

LIB

A1

Tags: Database

Similar Questions

  • LEFT JOIN DUPLICATION PROBLEM

    Hello

    I'm having a problem with the left join query, when I join table a two table based on column task1 I get duplicate in table1.task1, table1.price.

    Table1. Task1Table1. Pricetable2. Task1table2. Resourcetable2. Price
    001100001A50
    001100001B250

    How can I make a request to get a result as below.

    Table1. Task1Table1. Pricetable2.Task2table2. Resourcetable2. Price
    001100001A50
    001B250

    Thank you.

    Note that your query uses an inner join. Your original question mentioned a join left, generally interpreted as meaning a left OUTER join.

    Anyway, according to Frank, you can use the BREAK command in SQL * Plus for the goal sought through formatting. You can also use an analytical function as Roger suggests. I think ROW_NUMBER() might do the trick, but we must be clear about the criteria for partitioning and ordering the results, for example

    WITH table1 AS (
      SELECT '001' AS task1
           , 100 AS price
      FROM   dual
    ), table2 AS (
      SELECT '001' AS task1
           , 'A' AS resources
           , 50 AS price
      FROM   dual
      UNION ALL
      SELECT '001' AS task1
           , 'B' AS resources
           , 250 AS price
      FROM   dual
    )
    SELECT DECODE(ROW_NUMBER() OVER (PARTITION BY t1.task1, t1.price ORDER BY t2.resources, t2.price),1,t1.task1) AS task1_alt
         , DECODE(ROW_NUMBER() OVER (PARTITION BY t1.task1, t1.price ORDER BY t2.resources, t2.price),1,t1.price) AS price_alt
         , t2.task1 AS task_with_resource
         , t2.resources
         , t2.price
    FROM   table1 t1
    INNER JOIN table2 t2
    ON     t1.task1 = t2.task1
    ORDER BY t1.task1, t1.price, t2.resources, t2.price;
    
  • Strange view Domain Join Sysprep problem 5.3.1.

    I have a strange problem and I am pulling my hair out.  I have a win7 machine pool is not join the domain at all when dial or redial.  I use sysprep with a specification of customization that I have used for previous pools without problems.  I did a regular clone and use the specification of customization and everything went well.  I can fight my way through and get them joining the field via vcenter, but is not viable in the long term.  Out of curiosity, I logged into two so that they were waiting to start their sysprep (just after they have been cloned) and grabbed the sysprep.xml file.  They are identical, but with a major and an important difference in the identification of the sysprep.xml file section. The view composer, just looks like he wants to join the Working Group, while the clone of vcenter shows he wants to join the domain.  (Details below)  Is there that a difference in the way composer manages customization as vCenter?

    It sounds like what I expected (via the regular vcenter clone, details deleted):

    < identification >

    Domaine.org < JoinDomain > < / JoinDomain >

    < References >

    < username > [email protected] < / username >

    < EncryptedPassword > 8... 892 < / EncryptedPassword >

    Domaine.org < domain > < / domain >

    < / qualifications >

    < / identification >

    That's what one on linked clone desktops has, it looks like something a little 'good thars yer problem ":

    < identification >

    < JoinWorkgroup > WORKGROUP < / JoinWorkgroup >

    < / identification >

    Any help/info is appreciated.

    It was very weird, I had to support.  After several hours to prove what was going on, I transferred to the next call center who knew a guy who happened to remember a case strange and found an obscure article!  Here is the fix:

    http://KB.VMware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalID=2080397

  • Join the problem

    I am currently running Oracle version 11.1.0.7.0. I found a piece of view which I think does not behave as I expect. For me, this looks like a bug in Oracle, but I hope you can show me that this is not a bug and I hurt something else. I was able to reproduce this problem with these table definitions:

    create the table kaw_base
    (base_id number of non-null
    key constraint pk_kaw_base primary.
    subtype_code varchar2 (1)
    );

    create the table kaw_subtype1
    (base_id number of non-null
    key constraint pk_kaw_subtype1 primary.
    Order_Id varchar2 (16).
    constraint fk_subtype1__base
    foreign key (base_id) references kaw_base
    );

    create the table kaw_subtype2
    (base_id number of non-null
    key constraint pk_kaw_subtype2 primary.
    Order_Id varchar2 (16).
    constraint fk_subtype2__base
    foreign key (base_id) references kaw_base
    );

    create the table kaw_ref
    (ref_id number not null
    key constraint pk_kaw_ref primary.
    number of base_id not null
    constraint fk_ref__base
    Reference kaw_base
    );

    create indexes kaw_ref_ndx02
    on kaw_ref (base_id);

    I filled the tables with these data:

    insert into kaw_base
    Select 1, null of union double all the
    Select 2, '1' of any double Union
    Select 3, '1' of any double Union
    Select option 4, '2' from dual;
    Select * from kaw_base;

    insert into kaw_subtype1
    Select 2, '101' of any double union
    Select 3, '102' from dual;
    Select * from kaw_subtype1;

    insert into kaw_subtype2
    Select 4, '103' double;
    Select * from kaw_subtype2;

    insert into kaw_ref
    Select 500 + base_id, kaw_base base_id;
    Select * from kaw_ref;

    I then ran this series of requests to try to give the idea of what I see to this problem:

    -- --------------------------------------------------------
    -This first query shows the ID of lines which
    -must be returned by this query. Get all four rows
    -back and all is good in th world.
    --
    - But just try to add j.order_ID to the results!
    -- --------------------------------------------------------
    Select
    XREF.base_id
    -, j.order_Id
    of kaw_ref xRef
    Join
    -left join
    (select
    a.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    c left join kaw_subtype2
    -join kaw_subtype1 c on the left
    On c.base_id = a.base_id
    ) j
    On j.base_id = xref.base_id
    -where j.base_id is not null
    ;

    / * Sample output:
    BASE_ID
    ----------
    1
    2
    3
    4

    4 selected lines.
    */

    -- --------------------------------------------------------
    -What happened? I don't think that adding a column to
    -the selection list should cause the lines to completely
    -disappear.
    --
    -I walk what happens if I change the second LEFT JOIN
    - is the same as the first join?
    -- --------------------------------------------------------
    Select
    XREF.base_id
    j.order_Id
    of kaw_ref xRef
    Join
    -left join
    (select
    a.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    c left join kaw_subtype2
    -join kaw_subtype1 c on the left
    On c.base_id = a.base_id
    ) j
    On j.base_id = xref.base_id
    -where j.base_id is not null
    ;

    / * Sample output:

    no selected line.
    */

    -- --------------------------------------------------------
    -Still more curious. It seems to me that this could be
    -treatment he two LEFT joins as INNER joins and only
    -returning data with KAW_BASE and KAW_SUBTYPE1 in
    -common.
    --
    -We will try to change the rear query in a way that both
    -Joined LEFT pointing the two subtype tables and let's
    -also add, in the superfluous, WHERE clause and see what
    -makes for (for us).
    -- --------------------------------------------------------
    Select
    XREF.base_id
    j.order_Id
    of kaw_ref xRef
    Join
    -left join
    (select
    a.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    -join kaw_subtype2 c on the left
    c left join kaw_subtype1
    On c.base_id = a.base_id
    ) j
    On j.base_id = xref.base_id
    -where j.base_id is not null
    ;

    / * Sample output:

    BASE_ID ORDER_ID
    ---------- ----------------
    2 101
    3 102

    2 selected lines.
    */

    -- --------------------------------------------------------
    -OK, the superfluous where clause seems to provide a means
    -to work around this problem
    --
    -Will be LEFT JOIN more the WHERE clause also works
    - as a workaround?
    -- --------------------------------------------------------
    Select
    XREF.base_id
    j.order_Id
    of kaw_ref xRef
    Join
    -left join
    (select
    a.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    c left join kaw_subtype2
    -join kaw_subtype1 c on the left
    On c.base_id = a.base_id
    ) j
    On j.base_id = xref.base_id
    -- --------------------------------------------------------
    -Just comment on the WHERE clause:
    --
    -OK, this when the clause seems quite unnecessary.
    -However, for some unknown reason this where clause
    -must be included so that the select clause can
    -Returns the correct results
    --
    -Can anyone please tell me why when the clause is
    -necessary?
    -- --------------------------------------------------------
    where j.base_id is not null
    ;

    / * Sample output:

    BASE_ID ORDER_ID
    ---------- ----------------
    1
    2 101
    3 102
    4 103

    4 selected lines.
    */

    -- --------------------------------------------------------
    -The LEFT JOIN can also be used to circumvent this
    -publish; However, I prefer to avoid the kind of "from".
    de - facto' inner joins because they lead to questions
    -associated with what the original author intended.
    -in particular, the original author didn't intend to return
    -the data with an inner join or did the author really
    -intend to include the other ranks too, but make one
    -unusual coding error?
    --
    -Will use nested rather than using join syntax of
    -a table derived also solve this problem?
    -- --------------------------------------------------------
    Select
    XREF.base_id
    j.order_Id
    of kaw_ref xRef
    -join
    left join
    (select
    a.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    c left join kaw_subtype2
    -join kaw_subtype1 c on the left
    On c.base_id = a.base_id
    ) j
    On j.base_id = xref.base_id
    -- --------------------------------------------------------
    -This where clause should be included to convert the
    -an outer join in an inner join "de facto".
    -- --------------------------------------------------------
    where j.base_id is not null
    ;

    / * Sample output:

    BASE_ID ORDER_ID
    ---------- ----------------
    1
    2 101
    3 102
    4 103

    4 selected lines.
    */

    -- --------------------------------------------------------
    -Unfortunately, move to the nested join syntax
    -do not in itself solves this problem.
    --
    -Added in the redundant WHERE clause will provide
    -a work around?
    -- --------------------------------------------------------
    Select
    XREF.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_ref xRef
    Join
    (kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    c left join kaw_subtype2
    On c.base_id = a.base_id
    ) on a.base_id = xref.base_id
    -- --------------------------------------------------------
    -This where clause should be included to convert the
    -an outer join in an inner join "de facto".
    -- --------------------------------------------------------
    -where j.base_id is not null
    ;

    / * Sample output:

    no selected line.
    */

    -- --------------------------------------------------------
    -Adding the redundant search where clause provides
    -something that causes this query works correctly.
    --
    -Is this a bug?
    -- --------------------------------------------------------
    Select
    XREF.base_id,
    COALESCE(b.order_Id, c.Order_Id) as Order_Id
    of kaw_ref xRef
    Join
    (kaw_base one
    Join kaw_subtype1 b left
    On b.base_id = a.base_id
    c left join kaw_subtype2
    On c.base_id = a.base_id
    ) on a.base_id = xref.base_id
    -- --------------------------------------------------------
    -This where clause must be included as a work around to
    -to ensure that the correct rows will be returned
    -- --------------------------------------------------------
    where a.base_id is not null
    ;

    / * Sample output:

    BASE_ID ORDER_ID
    ---------- ----------------
    1
    2 101
    3 102
    4 103

    4 selected lines.
    */

    Can someone tell me what exactly is going on with this?

    Hello

    Would be - this bug #9011590 "bad results due to the elimination of the join?
    He described as possibly a regression introduced with 11.1.0.7 patch set.

    Oracle Support says 11.2 is affected too, but I can't reproduce with your test case.

    Just in case, you could try one of the following workarounds?

    alter session set "_optimizer_join_elimination_enabled" = false;
    
    alter session set "_fix_control" = '6167716:OFF';
    
  • Join cfquery problem

    I had a problem when I try to join these 3 tables and count the records in the subquery. If anyone can provide assistance with this... thnx.

    SELECT DISTINCT *.
    ((StSupportTroubleTicket t
    LEFT JOIN stEmployee e ON e.Emp_ID = t.UsersID)
    LEFT JOIN stTTdiscussion d d.ttID = t.ID)
    WHERE t.complete = 0 AND t.project = 0
    ORDER BY DESC t.ID

    I'm counting the records of stTTdiscussion.

    (it is a support trouble ticket program that has a comment on the post article. I am a type 15 comments interface digg.com and I would like to know the number of comments in this post.)

    DB MSAccess, win2K3, MX 6.1

    > Adam, the query I have here doesn't work.

    Hmmm. well, it's a start. I imitated your DB locally and it works for
    Me too. It could have been because I was doing a mix of RIGHT and LEFT
    outer joins when I came across a problem with access, the last time.

    In any case, that's what you want:

    SELECT t.ID, count (d.ttID) as discussionCount
    ((StSupportTroubleTicket t
    LEFT JOIN stEmployee e ON e.Emp_ID = t.UsersID)
    LEFT JOIN stTTdiscussion d d.ttID = t.ID)
    WHERE t.complete = 0 AND t.project = 0
    GROUP BY t.ID
    ORDER BY DESC t.ID

    --
    Adam

  • Multiple Table join result problem

    Hello

    I am new to oracle

    I am facing a problem to the exact result of multiple table.
    My query is


    Select e . e_name, t . Start_date, a. area_name , t . Branch of the , t . objective, ( t. actual_rtn_dt - t . Start_date) duration

    t of tour_info zone a, e method

    where actual_rtn_dt is not null

    and t. emp_code = e. emp_code

         and t. zone = a. Area_Code

    order t. start_date;

    -----------------------------------------------------------------

    Here is the result

    MD. KHAIRUL ISLAM01 SEP-14DHAKA_3071AUTOMATION6
    DEV SUDORSON02-SEP-14TRAINING DIISP2
    JUSTINE DIA04 SEP-14GAZIPURHUMAN RESOURCES REVIEW0
    SABRI AL RAHMAN04 SEP-14DHAKA_3071AUTOMATION WITH PKSF3
    MD. KHALEDUL ISLAM04 SEP-14GAZIPURHUMAN RESOURCES REVIEW0
    GAZI MD. SALAHUDDIN04 SEP-14GAZIPUR0
    MD. KHALEDUL ISLAM06 SEP-14071AUTOMATION0
    MD. JULIEE RAHMAN14-SEPT-11GAZIPURTRAINING2

    But I want to, in Bracnh column allows to extract branch_name Bracnh Tbal (I have on the database) as Area_name.

    How is it Possible?

    Thanks advanced

    SELECT e.e_name,
           t.start_date,
           a.area_name,
           --t.branch,
           (select branch_name from branch_tbl where =t.branch) branch_name,
           t.objective,
           ( t.actual_rtn_dt - t.start_date ) duration
    FROM   tour_info t,
           area a,
           emp_info e
    WHERE  actual_rtn_dt IS NOT NULL
           AND t.emp_code = e.emp_code
           AND t.area = a.area_code(+)
    ORDER  BY t.start_date;
    

    Is that what you are looking for?

  • force GBA v.5 to join the domain with a certain domain controller

    Hello world

    I try to join a CBS c. 5.3 to the domain.  My acs in A location, I can join without problem using my account. When I try to join the ACS in location B to the same domain with the same account, it does not work.

    I looked for the ad client debugging logs and noticed that the ACS in location B goes to some a domain controller. However, I would have expected the ACS to contact a different DC, located on the same site that GBA... This does not happen.

    My question: how to determine what contact DC GBA? Is it possible to force HQ to reach by connecting a certain DC?

    Thanks for any help or ideas?

    IDA

    Hello

    Please check your sites and services in your DNS configuration to see if the right domain controllers are sent to the ACS when attempting to connect to the domain. This function is essential and allows to optimize the links that GBA chooses to join the domain.

    The way this works is that ACS is trying to resolve dns records for the global catalog servers and domain controllers for the dns server configured in the initial installation script. Then the dns makes a decision based on the source ip address of the dns request and think that the ACS is in a specific site and returns the result which domain controllers and global catalogs is configured in this specific site.

    Let me know if this helps.

    Tarik Admani
    * Please note the useful messages *.

  • Subquery Factoring - cardinality estimate good but bad sql response times

    This is Exadata 11.2.0.4.0 database, all tables have statistics of up to date. Cardinality estimation is good compared to the actual cardinality. It is a way to tune this sql to reduce its response time.

    Sorry for the long sql and the execution plan.

    WITH SUBWITH0 AS
      (SELECT D1.c1 AS c1
      FROM (
        (SELECT D1.c1 AS c1
        FROM
          (SELECT DISTINCT T7171.CH_ID_SYM AS c1
          FROM DW.TM_R_REP T7171
          WHERE ( T7171.CHILD_REP_ID = 939 )
          ) D1
        UNION
        SELECT D1.c1 AS c1
        FROM
          (SELECT DISTINCT T7167.MEMBER_KEY_SYM AS c1
          FROM DW.PC_T_REP T7167
          WHERE ( T7167.ANCESTOR_KEY = 939 )
          ) D1
        ) ) D1
      ),
      SUBWITH1 AS
      (SELECT D1.c1 AS c1
      FROM (
        (SELECT D1.c1 AS c1
        FROM
          (SELECT DISTINCT T7171.CH_ID_SYM AS c1
          FROM DW.TM_R_REP T7171
          WHERE ( T7171.CHILD_REP_ID = 939 )
          ) D1
        UNION
        SELECT D1.c1 AS c1
        FROM
          (SELECT DISTINCT T7167.MEMBER_KEY_SYM AS c1
          FROM DW.PC_T_REP T7167
          WHERE ( T7167.ANCESTOR_KEY = 939 )
          ) D1
        ) ) D1
      ),
      SUBWITH2 AS
      (SELECT DISTINCT T7171.CH_ID_SYM AS c1
      FROM ( DW.PC_T_REP T7167
      LEFT OUTER JOIN DW.TM_R_REP T7171
      ON T7167.ANCESTOR_KEY    = T7171.CHILD_REP_ID
      AND T7167.SALESYEARMONTH = T7171.SALES_YEAR_MONTH)
      LEFT OUTER JOIN DW.TM_REP T6715
      ON T7171.CHILD_REP_ID_N = T6715.REP_ID
      WHERE (
        CASE
          WHEN T7171.CHILD_REP_ID_N LIKE '9999%'
          THEN concat(concat('UNASSIGNED', lpad(' ', 2)), CAST(T7167.TERRITORY_ID AS VARCHAR ( 20 ) ))
          ELSE concat(concat(concat(concat(T6715.FIRST_NAME, lpad(' ', 2)), T6715.MIDDLE_NAME), lpad(' ', 2)), T6715.LAST_NAME)
        END = 'JOES     CRAMER'
      AND T7171.SALES_YEAR_MONTH BETWEEN '201505' AND '201505'
      AND T7171.CH_ID_SYM IN
        (SELECT DISTINCT D1.c1 AS c1 FROM SUBWITH0 D1
        ) )
      ),
      SUBWITH3 AS
      (SELECT MEMBER_KEY_SYM AS c1
      FROM DW.PC_T_REP T7167
      WHERE ( IS_LEAF = 1 )
      ),
      SAWITH0 AS
      (SELECT DISTINCT
        CASE
          WHEN T7171.CHILD_REP_ID_N LIKE '9999%'
          THEN concat(concat('UNASSIGNED', lpad(' ', 2)), CAST(T7167.TERRITORY_ID AS VARCHAR ( 20 ) ))
          ELSE concat(concat(concat(concat(T6715.FIRST_NAME, lpad(' ', 2)), T6715.MIDDLE_NAME), lpad(' ', 2)), T6715.LAST_NAME)
        END                      AS c1,
        T6715.REP_NUM          AS c2,
        T7171.SALES_YEAR_MONTH AS c3,
        T7315.MONTH_NUMERIC    AS c4,
        CASE
          WHEN T7171.CH_ID_SYM IN
            (SELECT D1.c1 AS c1
            FROM SUBWITH3 D1
            )
          THEN 1
          ELSE 0
        END                                              AS c5,
        CAST(T7171.PARENT_REP_ID AS CHARACTER ( 30 ) ) AS c6,
        T7171.CH_ID_SYM                         AS c7,
        T7171.PARENT_REP_ID_SYM                        AS c8
      FROM DW.TIM_MON T7315
        ,
        ( ( DW.PC_T_REP T7167
      LEFT OUTER JOIN (
        (SELECT TO_NUMBER(TO_CHAR(L_OPP.CloseDate,'YYYYMM')) AS Sales_Year_Month,
          Tm_Rep.Rep_Id                                              AS Rep_Id,
          L_OPP.Account_Name__C                              AS Account_Name__C,
          L_OPP.Closedate                                    AS Closedate,
          L_OPP.Forecastcategory                             AS Forecastcategory,
          L_OPP.Forecastcategoryname                         AS Forecastcategoryname,
          L_User.NAME                                                AS Opp_Owner_S_Sales_Org__C,
          L_OPP.Opportunity_Id__C                            AS Opportunity_Id__C,
          L_OPP.Renewal_Date__C                              AS Renewal_Date__C,
          L_OPP.Total_Incremental__C                         AS Total_Incremental__C,
          L_OPP.Offer_Code__C                                AS Offer_Code__C,
          L_OPP.ID                                           AS Opportunity_ID,
          L_OPP.TERRITORYID                                  AS TERRITORYID,
          L_OPP.ACCOUNTID                                    AS ACCOUNTID,
          L_OPP.OWNERID                                      AS OWNERID,
          L_OPP.TOTAL_RENEWAL__C                             AS TOTAL_RENEWAL__C,
          L_OPP.NAME                                         AS NAME,
          L_OPP.STAGENAME                                    AS STAGE_NAME,
          L_OPP.STAGE_DESCRIPTION__C                         AS STAGE_DESCRIPTION,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory                = 'Closed'
            AND( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN L_OPP.Total_Incremental__C
          END , 0) AS Closed_Oppurtunity,
          CASE
            WHEN L_OPP.Forecastcategory                 = 'Closed'
            AND ( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN 'Closed_Oppurtunity_Drill'
          END AS Closed_Oppurtunity_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategoryname            IN ('Pipeline', 'Potential', 'Commit')
            AND ( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN L_OPP.Total_Incremental__C
          END , 0) AS OPEN_Oppurtunity,
          CASE
            WHEN L_OPP.Forecastcategoryname            IN ('Pipeline', 'Potential', 'Commit')
            AND ( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN 'OPEN_Oppurtunity_Drill'
          END AS OPEN_Oppurtunity_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year1_Closed_Opp,
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN 'Renewal_Year1_Closed_Opp_Drill'
          END AS Renewal_Year1_Closed_Opp_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year1_OPEN_Opp,
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN 'Renewal_Year1_OPEN_Opp_Drill'
          END AS Renewal_Year1_OPEN_Opp_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year2_Closed_Opp,
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN 'Renewal_Year2_Closed_Opp_Drill'
          END AS Renewal_Year2_Closed_Opp_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year2_OPEN_Opp,
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN 'Renewal_Year2_OPEN_Opp_Drill'
          END AS Renewal_Year2_OPEN_Opp_Drill
        FROM DW.OPP_C_DIM
        RIGHT OUTER JOIN RT.L_OPP
        ON (TO_CHAR(OPP_C_DIM.OFFER_CODE) =TO_CHAR(L_OPP.Offer_Code__C)
        AND (TO_CHAR(L_OPP.CloseDate,'YYYYMM'))  = TO_CHAR(OPP_C_DIM.PERIOD))
        LEFT OUTER JOIN RT.L_User
        ON (L_OPP.Ownerid=L_User.Id)
        LEFT OUTER JOIN DW.Tm_Rep
        ON (Tm_Rep.Rep_Num='0'
          ||L_User.Rep_Employee_Number__C)
        )) T774110 ON T7167.MEMBER_KEY = T774110.Rep_Id
      AND T7167.SALESYEARMONTH         = T774110.Sales_Year_Month)
      LEFT OUTER JOIN DW.TM_R_REP T7171
      ON T7167.ANCESTOR_KEY    = T7171.CHILD_REP_ID
      AND T7167.SALESYEARMONTH = T7171.SALES_YEAR_MONTH)
      LEFT OUTER JOIN DW.TM_REP T6715
      ON T7171.CHILD_REP_ID_N        = T6715.REP_ID
      WHERE ( T774110.Sales_Year_Month = T7315.YEAR_MONTH
      AND T7171.CH_ID_SYM    IN
        (SELECT DISTINCT D1.c1 AS c1 FROM SUBWITH2 D1
        )
      AND T7171.SALES_YEAR_MONTH BETWEEN '201505' AND '201505'
      AND T7171.CH_ID_SYM IN
        (SELECT DISTINCT D1.c1 AS c1 FROM SUBWITH1 D1
        ) )
      ),
      SAWITH1 AS
      (SELECT SUM(T774110.Renewal_Year2_OPEN_Opp) AS c9,
        SUM(T774110.Renewal_Year2_Closed_Opp)     AS c10,
        SUM(T774110.Renewal_Year1_OPEN_Opp)       AS c11,
        SUM(T774110.Renewal_Year1_Closed_Opp)     AS c12,
        SUM(T774110.OPEN_Oppurtunity)             AS c13,
        SUM(T774110.Closed_Oppurtunity)           AS c14,
        T7315.MONTH_NUMERIC                     AS c15,
        T7171.CH_ID_SYM                  AS c16
      FROM DW.TIM_MON T7315
        ,
        ( RT.L_ACCOUNT T765190
      LEFT OUTER JOIN ( DW.PC_T_REP T7167
      LEFT OUTER JOIN (
        (SELECT TO_NUMBER(TO_CHAR(L_OPP.CloseDate,'YYYYMM')) AS Sales_Year_Month,
          Tm_Rep.Rep_Id                                              AS Rep_Id,
          L_OPP.Account_Name__C                              AS Account_Name__C,
          L_OPP.Closedate                                    AS Closedate,
          L_OPP.Forecastcategory                             AS Forecastcategory,
          L_OPP.Forecastcategoryname                         AS Forecastcategoryname,
          L_User.NAME                                                AS Opp_Owner_S_Sales_Org__C,
          L_OPP.Opportunity_Id__C                            AS Opportunity_Id__C,
          L_OPP.Renewal_Date__C                              AS Renewal_Date__C,
          L_OPP.Total_Incremental__C                         AS Total_Incremental__C,
          L_OPP.Offer_Code__C                                AS Offer_Code__C,
          L_OPP.ID                                           AS Opportunity_ID,
          L_OPP.TERRITORYID                                  AS TERRITORYID,
          L_OPP.ACCOUNTID                                    AS ACCOUNTID,
          L_OPP.OWNERID                                      AS OWNERID,
          L_OPP.TOTAL_RENEWAL__C                             AS TOTAL_RENEWAL__C,
          L_OPP.NAME                                         AS NAME,
          L_OPP.STAGENAME                                    AS STAGE_NAME,
          L_OPP.STAGE_DESCRIPTION__C                         AS STAGE_DESCRIPTION,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory                = 'Closed'
            AND( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN L_OPP.Total_Incremental__C
          END , 0) AS Closed_Oppurtunity,
          CASE
            WHEN L_OPP.Forecastcategory                 = 'Closed'
            AND ( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN 'Closed_Oppurtunity_Drill'
          END AS Closed_Oppurtunity_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategoryname            IN ('Pipeline', 'Potential', 'Commit')
            AND ( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN L_OPP.Total_Incremental__C
          END , 0) AS OPEN_Oppurtunity,
          CASE
            WHEN L_OPP.Forecastcategoryname            IN ('Pipeline', 'Potential', 'Commit')
            AND ( OPP_C_DIM.OPPORTUNITIES_GROUP IS NULL )
            THEN 'OPEN_Oppurtunity_Drill'
          END AS OPEN_Oppurtunity_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year1_Closed_Opp,
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN 'Renewal_Year1_Closed_Opp_Drill'
          END AS Renewal_Year1_Closed_Opp_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year1_OPEN_Opp,
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL1'
            THEN 'Renewal_Year1_OPEN_Opp_Drill'
          END AS Renewal_Year1_OPEN_Opp_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year2_Closed_Opp,
          CASE
            WHEN L_OPP.Forecastcategory              = 'Closed'
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN 'Renewal_Year2_Closed_Opp_Drill'
          END AS Renewal_Year2_Closed_Opp_Drill,
          NVL(
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN L_OPP.TOTAL_RENEWAL__C
          END , 0) AS Renewal_Year2_OPEN_Opp,
          CASE
            WHEN L_OPP.Forecastcategory             IN ('Pipeline', 'Forecast', 'BestCase')
            AND OPP_C_DIM.OPPORTUNITIES_GROUP ='RENEWAL2'
            THEN 'Renewal_Year2_OPEN_Opp_Drill'
          END AS Renewal_Year2_OPEN_Opp_Drill
        FROM DW.OPP_C_DIM
        RIGHT OUTER JOIN RT.L_OPP
        ON (TO_CHAR(OPP_C_DIM.OFFER_CODE) =TO_CHAR(L_OPP.Offer_Code__C)
        AND (TO_CHAR(L_OPP.CloseDate,'YYYYMM'))  = TO_CHAR(OPP_C_DIM.PERIOD))
        LEFT OUTER JOIN RT.L_User
        ON (L_OPP.Ownerid=L_User.Id)
        LEFT OUTER JOIN DW.Tm_Rep
        ON (Tm_Rep.Rep_Num='0'
          ||L_User.Rep_Employee_Number__C)
        )) T774110 ON T7167.MEMBER_KEY = T774110.Rep_Id
      AND T7167.SALESYEARMONTH         = T774110.Sales_Year_Month) ON T765190.ID = T774110.ACCOUNTID)
      LEFT OUTER JOIN DW.TM_R_REP T7171
      ON T7167.ANCESTOR_KEY          = T7171.CHILD_REP_ID
      AND T7167.SALESYEARMONTH       = T7171.SALES_YEAR_MONTH
      WHERE ( T774110.Sales_Year_Month = T7315.YEAR_MONTH
      AND T7171.CH_ID_SYM    IN
        (SELECT DISTINCT D1.c1 AS c1 FROM SUBWITH2 D1
        )
      AND T7171.SALES_YEAR_MONTH BETWEEN '201505' AND '201505'
      AND T7171.CH_ID_SYM IN
        (SELECT DISTINCT D1.c1 AS c1 FROM SUBWITH1 D1
        ) )
      GROUP BY T7171.CH_ID_SYM,
        T7315.MONTH_NUMERIC
      )
    SELECT DISTINCT D2.c9 AS c1,
      D2.c10              AS c2,
      D2.c11              AS c3,
      D2.c12              AS c4,
      D2.c13              AS c5,
      D2.c14              AS c6,
      D1.c1               AS c7,
      D1.c2               AS c8,
      D1.c3               AS c9,
      D1.c4               AS c10,
      D1.c5               AS c11,
      D1.c6               AS c12,
      D1.c7               AS c13,
      D1.c8               AS c14
    FROM SAWITH0 D1
    INNER JOIN SAWITH1 D2
    ON SYS_OP_MAP_NONNULL(D2.c15)  = SYS_OP_MAP_NONNULL(D1.c4)
    AND SYS_OP_MAP_NONNULL(D2.c16) = SYS_OP_MAP_NONNULL(D1.c7)
    ORDER BY c10,
      c13
    
    
    

    SQL in real time, followed by the details with the Predicate Section of dbms_xplan.display_cursor shot

    Global stats

    ==============================================================================================================================

    | Elapsed.   CPU |    E/S | Request | Cluster |  Others | Pick up | Buffer | Read | Read | Write | Write |  Cell |

    | Time (s) | Time (s) | Waiting (s) |  Waiting (s) | Waiting (s) | Waiting (s) | Calls |  Gets | Reqs | Bytes | Reqs | Bytes | Unloading |

    ==============================================================================================================================

    |     152.     146.     3.73 |        0.08 |     0.04 |     2.04 |     2.    16 M | 5223.   1 GB |     1. 200KB |  95,11% |

    ==============================================================================================================================

    SQL details surveillance Plan (Plan hash value = 442312180)

    ===============================================================================================================================================================================================================================================

    | ID |                          Operation |            Name |  Lines | Cost |   Time | Start | Execs |   Lines | Read | Read |  Cell |  MEM | Activity |         Activity detail |

    |    |                                                              |                             | (Estimated) |       | Active (s) | Active |       | (Real) | Reqs | Bytes | Unloading | (Max) |   (%)    |           (Number of samples).

    ===============================================================================================================================================================================================================================================

    |  0 | SELECT STATEMENT |                             |         |       |         1.   152.     1.        0 |      |       |         |       |     0.65 | Cpu (1)                            |

    |  1.   RANGE OF PARTITION ALL THE |                             |       1.  3892 |           |        |     1.          |      |       |         |       |          |                                    |

    |  2.    ACCESS STORAGE FULL FIRST RANKS TABLE. PC_T_REP |       1.  3892 |           |        |    37.          |   74.  19 MB |  78.45% |   17 M |          |                                    |

    |  3.   TRANSFORMATION OF THE TEMPORARY TABLE.                             |         |       |         1.   152.     1.        1.      |       |         |       |          |                                    |

    |  4.    LOAD SELECT ACE |                             |         |       |         1.     + 5 |     1.        1.      |       |         |  278K |          |                                    |

    |  5.     VIEW                                                     |                             |     105.  3980 |         1.     + 5 |     1.    13637 |      |       |         |       |          |                                    |

    |  6.      SORT UNIQUE                                             |                             |     105.  3980 |         1.     + 5 |     1.    13637 |      |       |         |  757K |          |                                    |

    |  7.       UNION-ALL                                              |                             |         |       |         1.     + 5 |     1.    14033.      |       |         |       |          |                                    |

    |  8.        STORE TABLE FULL ACCESS | TM_R_REP |      22.    88.         1.     + 5 |     1.       36.      |       |         |       |          |                                    |

    |  9.        RANGE OF PARTITION ALL THE |                             |      83.  3890.         1.     + 5 |     1.    13997.      |       |         |       |          |                                    |

    | 10.         STORE TABLE FULL ACCESS | PC_T_REP |      83.  3890.         6.     + 0 |    37.    13997.      |       |         |    2 M |     0.65 | Smart cell table scan (1) |

    | 11.    LOAD SELECT ACE |                             |         |       |         1.     + 5 |     1.        1.      |       |         |  278K |          |                                    |

    | 12.     HASH UNIQUE                                              |                             |       1.  4166.         1.     + 5 |     1.        1.      |       |         |  479K |          |                                    |

    | 13.      HASH JOIN                                               |                             |       1.  4165 |         1.     + 5 |     1.      444.      |       |         |    1 M |          |                                    |

    | 14.       JOIN FILTER PART CREATE | : BF0000 |       3.  4075 |         1.     + 5 |     1.      549.      |       |         |       |          |                                    |

    | 15.        OUTER HASH JOIN |                             |       3.  4075 |         1.     + 5 |     1.      549.      |       |         |    1 M |          |                                    |

    | 16.         HASH JOIN                                            |                             |       3.  4068 |         1.     + 5 |     1.      549.      |       |         |    2 M |          |                                    |

    | 17.          VIEW                                                |                             |     105.  3980 |         1.     + 5 |     1.    13637 |      |       |         |       |          |                                    |

    | 18.           SORT UNIQUE                                        |                             |     105.  3980 |         1.     + 5 |     1.    13637 |      |       |         |  757K |          |                                    |

    | 19.            UNION-ALL                                         |                             |         |       |         1.     + 5 |     1.    14033.      |       |         |       |          |                                    |

    | 20.             STORE TABLE FULL ACCESS | TM_R_REP |      22.    88.         1.     + 5 |     1.       36.      |       |         |       |          |                                    |

    | 21.             RANGE OF PARTITION ALL THE |                             |      83.  3890.         1.     + 5 |     1.    13997.      |       |         |       |          |                                    |

    | 22.              STORE TABLE FULL ACCESS | PC_T_REP |      83.  3890.         1.     + 5 |    37.    13997.      |       |         |    2 M |          |                                    |

    | 23.          STORE TABLE FULL ACCESS | TM_R_REP |    1884 |    88.         1.     + 5 |     1.     1929 |      |       |         |       |          |                                    |

    | 24.         STORE TABLE FULL ACCESS | TM_REP                      |    7136 |     7.         1.     + 5 |     1.     7137 |      |       |         |       |          |                                    |

    | 25.       RANGE OF SINGLE PARTITION |                             |    7449.    90.         1.     + 5 |     1.     7449.      |       |         |       |          |                                    |

    | 26.        STORE TABLE FULL ACCESS | PC_T_REP |    7449.    90.         1.     + 5 |     1.     7449.      |       |         |       |          |                                    |

    | 27.    SORT UNIQUE                                               |                             |       1. 26032 |         1.   152.     1.        1.      |       |         |  2048 |          |                                    |

    | 28.     OUTER HASH JOIN |                             |       1. 26031 |        72.    + 81 |     1.     8238 |      |       |         |    4 M |          |                                    |

    | 29.      FILTER                                                  |                             |         |       |        74.    + 79 |     1.     8238 |      |       |         |       |     1.96 | Cpu (3)                            |

    | 30.       NESTED EXTERNAL LOOPS |                             |       1. 26027 |        72.    + 81 |     1.      15 M |      |       |         |       |     3.27 | Cpu (5)                            |

    | 31.        HASH JOIN                                             |                             |       1. 26026 |        72.    + 81 |     1.      15 M |      |       |         |  447K |    18.95 | Cpu (29)                           |

    | 32.         OUTER HASH JOIN |                             |       1. 13213 |         1.    + 81 |     1.      332.      |       |         |  452K |          |                                    |

    | 33.          HASH JOIN                                           |                             |       1. 13206 |         1.    + 81 |     1.      332.      |       |         |    1 M |          |                                    |

    | 34.           HASH JOIN                                          |                             |       1. 13199.         1.    + 81 |     1.      444.      |       |         |  434K |          |                                    |

    | 35.            HASH JOIN                                         |                             |       1. 13197.         1.    + 81 |     1.      444.      |       |         |  290K |          |                                    |

    | 36.             JOIN CREATE FILTER | : BF0000 |       1. 13195.         1.    + 81 |     1.      444.      |       |         |       |          |                                    |

    | 37.              HASH JOIN                                       |                             |       1. 13195.         1.    + 81 |     1.      444.      |       |         |    2 M |          |                                    |

    | 38.               THE CARTESIAN MERGE JOIN.                             |      27. 13107 |         1.    + 81 |     1.     7449.      |       |         |       |          |                                    |

    | 39.                HASH JOIN                                     |                             |       1. 13017.        77.     + 5 |     1.        1.      |       |         |  750K |          |                                    |

    | 40.                 STORE TABLE FULL ACCESS | TIM_MON |       1.     4.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 41.                 VIEW                                         |                             |       1. 13013.         1.    + 81 |     1.        1.      |       |         |       |          |                                    |

    | 42.                  HASH GROUP BY.                             |       1. 13013.         1.    + 81 |     1.        1.      |       |         |  482K |          |                                    |

    | 43.                   OUTER HASH JOIN |                             |       1. 13012.        77.     + 5 |     1.     8238 |      |       |         |    4 M |          |                                    |

    | 44.                    NESTED LOOPS |                             |       1. 13008.        77.     + 5 |     1.     8238 |      |       |         |       |          |                                    |

    | 45.                     FILTER                                   |                             |         |       |        77.     + 5 |     1.     8238 |      |       |         |       |     2.61 | Cpu (4)                            |

    | 46.                      NESTED EXTERNAL LOOPS |                             |       1. 13007.        77.     + 5 |     1.      15 M |      |       |         |       |     4.58. Cpu (7)                            |

    | 47.                       HASH JOIN                              |                             |       1. 13006.        77.     + 5 |     1.      15 M |      |       |         |  424K |    11.76. Cpu (18)                           |

    | 48.                        HASH JOIN |                             |       1.   193.         1.     + 5 |     1.      332.      |       |         |    1 M |          |                                    |

    | 49.                         HASH JOIN |                             |       1.   186.         1.     + 5 |     1.      444.      |       |         |  420K |          |                                    |

    | 50.                          HASH JOIN |                             |       4.   184.         1.     + 5 |     1.      444.      |       |         |  290K |          |                                    |

    | 51.                           JOIN CREATE FILTER | : BF0002 |       1.    94.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 52.                            JOIN FILTER PART CREATE | : BF0001 |       1.    94.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 53.                             HASH JOIN |                             |       1.    94.         1.     + 5 |     1.        1.      |       |         |  290K |          |                                    |

    | 54.                              JOIN CREATE FILTER | : BF0003 |       1.     6.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 55.                               THE CARTESIAN MERGE JOIN.                             |       1.     6.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 56.                                STORE TABLE FULL ACCESS | TIM_MON |       1.     4.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 57.                                KIND OF BUFFER.                             |       1.     2.         1.     + 5 |     1.        1.      |       |         |  2048 |          |                                    |

    | 58.                                 VIEW                         | VW_NSO_1 |       1.     2.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 59.                                  UNIQUE HASH |                             |       1.       |         1.     + 5 |     1.        1.      |       |         |  485K |          |                                    |

    | 60.                                   VIEW                       |                             |       1.     2.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 61.                                    STORE TABLE FULL ACCESS | SYS_TEMP_0FD9D71E1_B445AE36 |       1.     2.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 62.                              USE OF JOIN FILTER | : BF0003 |    1884 |    88.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 63.                               STORE TABLE FULL ACCESS | TM_R_REP |    1884 |    88.         1.     + 5 |     1.        1.      |       |         |       |          |                                    |

    | 64.                           USE OF JOIN FILTER | : BF0002 |    7449.    90.         1.     + 5 |     1.      444.      |       |         |       |          |                                    |

    | 65.                            RANGE OF SINGLE PARTITION |                             |    7449.    90.         5.     + 1 |     1.      444.      |       |         |       |     0.65 | Cpu (1)                            |

    | 66.                             STORE TABLE FULL ACCESS | PC_T_REP |    7449.    90.         1.     + 5 |     1.      444.      |       |         |       |          |                                    |

    | 67.                          VIEW                                |                             |     105.     2.         1.     + 5 |     1.    13637 |      |       |         |       |          |                                    |

    | 68.                           STORE TABLE FULL ACCESS | SYS_TEMP_0FD9D71E0_B445AE36 |     105.     2.         1.     + 5 |     1.    13637 |      |       |         |       |          |                                    |

    | 69.                         STORE TABLE FULL ACCESS | TM_REP                      |    7136 |     7.         1.     + 5 |     1.     7137 |      |       |         |       |          |                                    |

    | 70.                        STORE TABLE FULL ACCESS | L_OP                        |   19382 | 12813 |        77.     + 5 |     1.    43879 |  565. 551 MB |  98.18% |   15 M |          |                                    |

    | 71.                       TABLE ACCESS BY INDEX ROWID | L_US                        |       1.     1.        79.     + 3 |   15 M |      15 M |   26. 208KO |         |       |    19.61 | Cpu (30)                           |

    | 72.                        INDEX UNIQUE SCAN | L_US_PK                     |       1.       |        77.     + 5 |   15 M |      15 M |    2. 16384.         |       |     9 h 15 | Cpu (14)                           |

    | 73.                     INDEX UNIQUE SCAN | L_A_PK                      |       1.     1.       151.     + 2 |  8238 |     8238 | 3269 |  26 MB |         |       |     2.61 | Cpu (1)                            |

    |    |                                                              |                             |         |       |           |        |       |          |      |       |         |       |          | monobloc cell physical read (3) |

    | 74.                    STORE TABLE FULL ACCESS | OPP_C_DIM |    2304 |     4.         1.    + 81 |     1.     2304 |    3. 112 KB |         |       |          |                                    |

    | 75.                KIND OF BUFFER.                             |    7449. 13107 |         1.    + 81 |     1.     7449.      |       |         |  370K |          |                                    |

    | 76.                 RANGE OF SINGLE PARTITION |                             |    7449.    90.         1.    + 81 |     1.     7449.      |       |         |       |          |                                    |

    | 77.                  STORE TABLE FULL ACCESS | PC_T_REP |    7449.    90.         1.    + 81 |     1.     7449.      |       |         |       |          |                                    |

    | 78.               STORE TABLE FULL ACCESS | TM_R_REP |    1884 |    88.         1.    + 81 |     1.     1929 |      |       |         |       |          |                                    |

    | 79.             VIEW                                             |                             |       1.     2.         1.    + 81 |     1.        1.      |       |         |       |          |                                    |

    | 80.              USE OF JOIN FILTER | : BF0000 |       1.     2.         1.    + 81 |     1.        1.      |       |         |       |          |                                    |

    | 81.               STORE TABLE FULL ACCESS | SYS_TEMP_0FD9D71E1_B445AE36 |       1.     2.         1.    + 81 |     1.        1.      |       |         |       |          |                                    |

    | 82.            VIEW                                              |                             |     105.     2.         1.    + 81 |     1.    13637 |      |       |         |       |          |                                    |

    | 83.             STORE TABLE FULL ACCESS | SYS_TEMP_0FD9D71E0_B445AE36 |     105.     2.         1.    + 81 |     1.    13637 |      |       |         |       |          |                                    |

    | 84.           STORE TABLE FULL ACCESS | TM_REP                      |    7136 |     7.         1.    + 81 |     1.     7137 |      |       |         |       |          |                                    |

    | 85.          STORE TABLE FULL ACCESS | TM_REP                      |    7136 |     7.         1.    + 81 |     1.     7137 |      |       |         |       |          |                                    |

    | 86.         STORE TABLE FULL ACCESS | L_OP                        |   19382 | 12813 |        72.    + 81 |     1.    43879 |  593. 577 MB |  98,44% |   15 M |          |                                    |

    | 87.        TABLE ACCESS BY INDEX ROWID | L_US                        |       1.     1.        72.    + 81 |   15 M |      15 M |      |       |         |       |    13.73. Cpu (21)                           |

    | 88.         INDEX UNIQUE SCAN | L_US_PK                     |       1.       |        73.    + 80 |   15 M |      15 M |      |       |         |       |     9.80 | Cpu (15)                           |

    | 89.      STORE TABLE FULL ACCESS | OPP_C_DIM |    2304 |     4.         1.   152.     1.     2304 |      |       |         |       |          |                                    |

    ===============================================================================================================================================================================================================================================

    Information of predicates (identified by the operation identity card):

    ---------------------------------------------------

    2. (("MEMBER_KEY_SYM" =: B1 ET "IS_LEAF" = 1) filter)

    8 - storage("T7171".") CHILD_REP_ID "= 939)

    filter ("T7171". ("CHILD_REP_ID" = 939)

    10 - storage("T7167".") ANCESTOR_KEY "= 939)

    filter ("T7167". ("ANCESTOR_KEY" = 939)

    13 - access("T7167".") SALESYEARMONTH "= 'T7171'." SALES_YEAR_MONTH' AND 'T7167 '. "ANCESTOR_KEY"= "T7171". ("' CHILD_REP_ID")

    filter (CASE WHEN TO_CHAR ("T7171". "CHILD_REP_ID_N") AS 9999% ' THEN 'ALL UNASSIGNED' | " CAST ("T7167". ("TERRITORY_ID" AS A VARCHAR (20)) ELSE 'T6715 '. "" NAME "| "

    '||" T6715 ". "" MIDDLE_NAME "| "  '||" T6715 ". ("" LAST_NAME "END ="JOES CRAMER")

    15 - access("T7171".") CHILD_REP_ID_N "= 'T6715'." REP_ID")

    16 - access("T7171".") CH_ID_SYM '= 'D1'.' C1")

    20 - storage("T7171".") CHILD_REP_ID "= 939)

    filter ("T7171". ("CHILD_REP_ID" = 939)

    22 - storage("T7167".") ANCESTOR_KEY "= 939)

    filter ("T7167". ("ANCESTOR_KEY" = 939)

    23 - storage("T7171".") SALES_YEAR_MONTH "= 201505)

    filter ("T7171". ("SALES_YEAR_MONTH" = 201505)

    26 - storage("T7167".") SALESYEARMONTH "= 201505)

    filter ("T7167". ("SALESYEARMONTH" = 201505)

    28 - access (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM") = TO_CHAR ("OPP_C_DIM". " PERIOD") AND

    TO_CHAR ("OPP_C_DIM". "OFFER_CODE") = "L_OP". ("' OFFER_CODE__C")

    29 - filter("TM_REP".") REP_NUM "=" 0"|" » « « « L_US «. » REP_EMPLOYEE_NUMBER__C')

    31 - access("T7315".") YEAR_MONTH «= TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP".» CLOSEDATE"),"YYYYMM")) AND

    'T7167 '. «SALESYEARMONTH «= TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP".» (((("" CLOSEDATE "),"YYYYMM")))

    32 - access("T7171".") CHILD_REP_ID_N "= 'T6715'." REP_ID")

    33 - access("T7167".") MEMBER_KEY "=" TM_REP. " ("" REP_ID ")

    34 - access("T7171".") CH_ID_SYM '= 'D1'.' C1")

    35 - access("T7171".") CH_ID_SYM '= 'D1'.' C1")

    37 - access (SYS_OP_MAP_NONNULL ("D2". "C16") = SYS_OP_MAP_NONNULL ("T7171". " CH_ID_SYM") AND"T7167 ". "SALESYEARMONTH"= "T7171". "" SALES_YEAR_MONTH "AND

    'T7167 '. "ANCESTOR_KEY"= "T7171". ("' CHILD_REP_ID")

    39 - access (SYS_OP_MAP_NONNULL ("D2". "C15") = SYS_OP_MAP_NONNULL ("T7315". " MONTH_NUMERIC'))

    40 - storage("T7315".") YEAR_MONTH "= 201505)

    filter ("T7315". ("YEAR_MONTH" = 201505)

    43 - access (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM") = TO_CHAR ("OPP_C_DIM". " PERIOD") AND

    TO_CHAR ("OPP_C_DIM". "OFFER_CODE") = "L_OP". ("' OFFER_CODE__C")

    45 - filter("TM_REP".") REP_NUM "=" 0"|" » « « « L_US «. » REP_EMPLOYEE_NUMBER__C')

    47 - access("T7315".") YEAR_MONTH «= TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP".» CLOSEDATE"),"YYYYMM")) AND

    'T7167 '. «SALESYEARMONTH «= TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP".» (((("" CLOSEDATE "),"YYYYMM")))

    48 - access("T7167".") MEMBER_KEY "=" TM_REP. " ("" REP_ID ")

    49 - access("T7171".") CH_ID_SYM '= 'D1'.' C1")

    50 - access("T7167".") SALESYEARMONTH "= 'T7171'." SALES_YEAR_MONTH' AND 'T7167 '. "ANCESTOR_KEY"= "T7171". ("' CHILD_REP_ID")

    53 - access("T7171".") CH_ID_SYM "=" C1")

    56 - storage("T7315".") YEAR_MONTH "= 201505)

    filter ("T7315". ("YEAR_MONTH" = 201505)

    63 - storage (("T7171". "SALES_YEAR_MONTH" = 201505 AND SYS_OP_BLOOM_FILTER (: BF0000, "T7171" ".") CH_ID_SYM')))

    filter (("T7171". "SALES_YEAR_MONTH" = 201505 AND SYS_OP_BLOOM_FILTER (: BF0000, "T7171" ".") CH_ID_SYM')))

    66 - storage (("T7167". "SALESYEARMONTH" = 201505 AND SYS_OP_BLOOM_FILTER (: BF0000, "T7167" ".") SALESYEARMONTH', 'T7167 '. ((("" ANCESTOR_KEY ")))

    filter (("T7167". "SALESYEARMONTH" = 201505 AND SYS_OP_BLOOM_FILTER (: BF0000, "T7167" ".") SALESYEARMONTH', 'T7167 '. ((("" ANCESTOR_KEY ")))

    70 - storage ((TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) > = 201505 AND "

    TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) (< = 201505)) "

    filter ((TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) > = 201505 AND "

    TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) (< = 201505)) "

    72 - access("L_OP".") OWNERID "=" L_US. " (' ' ID ')

    73 - access("T765190".") WITH THE ID "=" L_OP. " ("' ACCOUNTID ')

    77 - storage("T7167".") SALESYEARMONTH "= 201505)

    filter ("T7167". ("SALESYEARMONTH" = 201505)

    78 - storage("T7171".") SALES_YEAR_MONTH "= 201505)

    filter ("T7171". ("SALES_YEAR_MONTH" = 201505)

    81 - storage (SYS_OP_BLOOM_FILTER (: BF0000, "C0"))

    filter (SYS_OP_BLOOM_FILTER (: BF0000, "C0"))

    86 - storage ((TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) > = 201505 AND "

    TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) (< = 201505)) "

    filter ((TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) > = 201505 AND "

    TO_NUMBER (TO_CHAR (INTERNAL_FUNCTION ("L_OP". "CLOSEDATE"), "YYYYMM")) (< = 201505)) "

    88 - access("L_OP".") OWNERID "=" L_US. " (' ' ID ')


    Note

    -----

    -dynamic sample used for this survey (level = 4)

    -Automatic DOP: calculated degree of parallelism is 1 because of the parallel threshold



    Although the table meet statistical why dynamic sampling is to be used? Why 15 million times ID 71, 72, 87 and 88 are executed, curious because that is where most of the time is spent. How can we reduce this 15 million probes?

    Suggestions to reduce the response time sql would be useful.

    Post edited by: Yasu masking of sensitive information (literal value)

    YASU says:

    For educational purposes could you please clarify why the optimizer has evaluated the join condition in the functioning of the FILTER to 15 million lines?

    This is unusual, but TM_REP is attached to another PC_T_REP table using a join operation, so maybe it's the explanation of why it is moved to a FILTER operation had been delayed - could also be a side effect of the combination of ANSI join processing (Oracle internally transforms ANSI joins in Oracle join syntax) and the transformation of outer join internally.

    Very curious to know how this is possible, could you please give us the hint/tour, you can use to push the inner join down execution plan is evaluated as soon as possible to reduce the data to be processed? I have a sql plus, where the situation is almost similar - ranks of filtering 2 million to the hash JOIN operation and return 0 rows. I can post the details of sql here but not to mix different sql question in the same post. Please let me know if you would like to give the details of this sql in this same thread, or a different thread? I searched for this type of information, but to no avail, so could you please suggest how this is possible, if not for this long sql then at least please provide a few examples/suggestions?

    Normally you can influence this through the appropriate join order, for example with the help of the LEADING indicator, for filter indicator PUSH_SUBQ subqueries can also be useful for filtering at the beginning. But here the comment of Franck is particularly important - by leaning on the Cartesian join this problem here should be less relevant.

    As I already said I would recommend here from scratch and think that all that this query is supposed to average and the question why most outer joins is actually converted into inner joins - the current query example returns the correct result?

    Randolf

  • relationship of 3 blocks in forms 10g

    Hi guys,.

    Thanks in advance

    I created three block A, B and C,.

    One block a Join B

    Block B has Join C.

    Problem is when I click block to block B to add the new record, the form erase all records of B and C

    Any help?

    orasadi wrote:
    Guys,

    I think that you don't get me,

    For example I have some records in the query, a block have some lines and block B has a few lines and C have also put away,

    Now, I'm going to add a line in block B, what happen form clear as all the lines of the block B and block C and my cursor come to the first rows on the B block.

    Yes, sometimes it's happened.

    What you have to do?
    1 remove the relationship between A & B and C & B
    2. manually create the relationship and Rename the relationship

    It works...

    Hamid

  • Solve a problem by getting an Airport Extreme to join my network.

    Greetings,

    I have a WiFi network, consisting of a router TimeMachine (primary Base Station), the AirPort Extreme Base Station and expansion of the Airport Express network

    I receive notification messages for these devices utility AirPort (Enter Password) - probably updates lately.  I do not know the passwords for these devices because I've had them so long and after initial installation and many updates of OS X I couldn't find entries for them in Keychain Access.

    Today, I made an attempt to reset the Airport Extreme to try and go through the installation routine and have the opportunity to create a new password and save it.  First of all, I did a soft reset and then tried a hard reset.  The results were the same for either - one error as follows...  Airport Extreme fits factory currently.  It is plugged in and running with a light orange blinking.  She appears in the WiFi menu as a new Airport base station.  Selecting menu launches Airport utility and a dialog box drop-down connection.  The dialog box States "collecting information on your network - preparation, Joining Airport Extreme and finally"an unexpected error has occurred, try again"there is a very brief message (.5sec) before the last error - try again.»  In my view, that it is said 'Extreme Base Station on your network'.  This could mean that because the TimeMachine works as the main base station, the Airport Extreme Base cannot be joined so that I can Setup/modify it.

    Ultimately I'd like to get the issue resolved for all three devices password, but I'm a little gushy now after this attempt

    Someone has an idea how to proceed.

    Thanks Dave

    There are several things going on, but you can fix pretty quickly is the password. It is a piece of information that you should really have - now and for the future. You can reset your password by sticking the end of a paper clip in the back of the airport for more than ten seconds. You will see the configuration on the Airport utility screen. Do not forget your password in the future.  At the end of this operation, you can see a firmware view - to take care of that.

    Once your airport is reset, and the password is updated and updates, you can see if there are any problems - if any. If there are additional questions, you can include a photo of the Airport utility screen.

  • Firefox fail to join the doc in the mail and asking for using classic uploader. Look more early not this problem

    Firefox fail to join the doc in e-mail indicating that it might be due to proxy or firewall and to ask for the classic Loader help
    This problem was earlier not existing does not
    This isn't the problem with internet explore

    I have already updated to version 9.0.1 and I can't yet nothing attached to an e-mail. I did have this problem with a previous version of Firefox. What did you do to the system? It's very annoying.

  • iPhone wifi problem 6 ios 9.2.1. WiFi show still unable to join or incorrect password! Help, please

    iPhone wifi problem 6 ios 9.2.1. WiFi show still unable to join or incorrect password! Help, please

    You need the correct password to join any Wi - Fi hotspot which are not free.

    When you try to connect to Wi - Fi.

    Have you tried

    Settings > general > reset > reset network settings?

  • Problems with Server 2008 R2 Kerberos with Mac and CentOS machines? Need to re - join domain

    We are having a problem with our Mac and Linux / CentOS machines constantly having to be re-attached to our AD domain.
    We are able to join machines to the domain successfully, but after a few weeks or if authentication is broken and we again join them to the domain.
    I see Security event logs on our domain controller when kerberos authentication fails.
    On the linux server - I see this message in the logs
    -binding failed: server not found in the kerberos database.

    I'm guessing this has to do with Server 2008 R2 and incompatible mac / linux versions.

    Any ideas?

    Hello

    I suggest you try to post the question in the forums and check them off below if it helps:

    http://social.technet.Microsoft.com/forums/en-us/windowsserver2008r2general/threads

    It will be useful.

  • Problem to join a domain with Windows Vista Bussiness

    I have my domian with Windows Server 2008 standard, on my network, I have Windows XP, 2000, Win7 and Vista computers and laptops.

    I have no problem to join all computers, but when I try to join a computer or laptop with Vista it keeps giving me this error:

    "An attempt to resolve the DNS of a domain controller in the domain being joined has failed. Please check that this client is set to reach a DNS server that can resolve DNS names in the target area.

    I already do a little research on the web and try disabling IPv6, I also create the computer in the ad before attempting to join the domain, so far without success.

    Thanks in advance for your answers!

    Hi Arturo,.

    Your question is more complex than what is generally answered in the Microsoft Answers forums. It is better suited for the IT Pro TechNet public. Please ask your question in the following forum.

    Windows Server - general forum

  • Problems to join the homegroup.

    Hello, I installed windows 7 Professional on 2 PCs at my home. I need to work with the networking of the homegroup. I tried to create the network in both computers, but the other do not recognize when I try to join the homegroup. I tried solving the problems in both computers, but nothing happens. I changed the name of the Working Group, but the problem is still there. I tried everything I had read in the forums, but nothing happens. I would be happy if you could help me.

    PS: Sorry if my English is not the best

    Hi Dmpalma.

    This is a doc that might help you: http://windows.microsoft.com/en-US/windows7/Why-can-t-I-join-a-homegroup

    Other things to try:

    1. ensure that your computers have different computer names.
    2. try to leave the homegroup on both computers, restart both computers, and then start again (create the homegroup on one computer, and then join him another computer)

    Thank you
    Gloria Boyer
    Microsoft

Maybe you are looking for

  • IPhone 1st generation

    Hello world. I have an iphone 1st generation with a screen broke and I can't find a service to fix it. I love this camera and I really want to make it functional again.  Any suggestions?  Thank you

  • Satellite Pro A10 - no wireless network card are not not in Device Manager

    Can you help me - Toshiba Satellite Pro A10Model no PSA15E-01PFQ-FRSeries No Y3602494GWindows XP Pro On the front of this laptop is a wireless switch - this switch is set on, Windows XP Pro can't find any wireless device - Windows Device Manager show

  • HP's envy touchsmart: default speakers continues to change

    I'm a 15tQuad TouchSmart laptop hooked up to a Dell monitor. I always keep the laptop closed except when that I start or when the monitor goes to sleep and I need to wake up again. My sound worked very well and knew that the default was the audio dev

  • 10 tips, tricks and hacks for Windows 8

    Preston gralla to the world of computing has created a document that some useful tips (some more than others) that can be useful or just what you are looking for. Here is the article about the various tips and tricks. NOTE: HP is not affiliated with

  • No point endpoint name when SX20 Multisite conference

    Hello I have install a lab which consist of 2 SX20 and 1 EX60. Using SIP and any call control, trying to conference with capacity multisite SX20 (just call using the [email protected] / * /). But, I noticed there is no display name below each partici