• 再次遇到谓词推入


    explain plan for 
    with aa as
     (select 
             a.agmt_id,
             sum(c.acct_bal) as card_bal, --借记卡期末存款余额
             a.card_open_org,
             a.OPEN_DATE, -- 发卡日期     
             a.CARD_NEW_STATUS, -- 卡片状态    
             a.cust_magr, -- 客户经理号 
             a.cust_no, -- 客户号
             a.corp_org
        from dwf.f_agt_cadb_book_h a
        left outer join (select agmt_id, acct_no
                          from dwf.f_agt_cadb_acct
                         where substr(acct_status, 8, 1) <> '2') b
          on a.master_card_no = b.agmt_id
      
        left outer join (select agmt_id, max(last_trans_date) last_trans_date, sum(acct_bal) acct_bal
                          from dwf.F_AGT_SAVB_ACCTINFO_H
                         where start_dt <= to_date('2014-03-31', 'YYYY-MM-DD')
                           and end_dt > to_date('2014-03-31', 'YYYY-MM-DD')
                           and acct_status <> '1'
                           group by  agmt_id
                           
                           ) c  -- 一卡多账号,某一账号睡眠其它未睡 ,卡账务信息表最后交易日期不准
          on b.acct_no = c.agmt_id
       where substr(a.host_card_status, 8, 1) = '0' --卡状态不为注销
         and a.master_card_no is not null --剔除待领卡
         and a.start_dt <= to_date('2014-03-31', 'YYYY-MM-DD') /*参数传入 季末日期*/
         and a.end_dt > to_date('2014-03-31', 'YYYY-MM-DD') /*参数传入 季末日期*/
         and c.LAST_TRANS_DATE < to_date( '2014-03-01', 'YYYY-MM-DD') /*参数传入 季末日期*/
         and c.acct_bal is not null
       group by a.agmt_id,
                a.card_open_org,
                a.OPEN_DATE, -- 发卡日期     
                a.CARD_NEW_STATUS, -- 卡片状态    
                a.cust_magr, -- 客户经理号  
                a.cust_no, -- 客户号
                a.corp_org
      having(sum(c.acct_bal) < 10)),
    
    bb as
     (SELECT xx.tran_card_no, count(1) cnt, max(xx.trans_date) max_date
        FROM DWF.F_EVT_CADJ_JOUR xx
       WHERE TRANS_DATE <= to_date('2014-03-31', 'YYYY-MM-DD')
       group by xx.tran_card_no)
       
       
    
    select aa.agmt_id, -- 卡号        
           'J' AS CARD_T, -- 卡种类      
           f.pty_name, -- 客户姓名    
           aa.cust_no, -- 客户证件号  
           f.mobile_no, -- 客户手机号  
           aa.OPEN_DATE, -- 发卡日期    
           null as ACTIVEDAY, -- 激活日期    
           aa.CARD_NEW_STATUS, -- 卡片状态    
           to_date('2014-03-31', 'YYYY-MM-DD') - nvl(bb.MAX_DATE, aa.OPEN_DATE) as sleep_day, -- 睡眠时间    
           card_bal, -- 存款余额    
           null as cred_limit, -- 授信额度    
           bb.cnt, -- 交易次数    
           aa.cust_magr, -- 客户经理号  
           xx.emp_name, -- 客户经理名称
           aa.card_open_org, -- 所属机构  
           bb.MAX_DATE
      from aa
      left join bb
        on aa.agmt_id = bb.tran_card_no
      LEFT JOIN dwm.v_m_pty_emp_info xx --员工表
        ON aa.cust_magr = xx.pty_id
       AND xx.start_dt <= to_date('2014-03-31', 'YYYY-MM-DD')
       AND xx.end_dt > to_date('2014-03-31', 'YYYY-MM-DD')
      LEFT JOIN dwf.f_pty_table f --当事人主表
        ON aa.cust_no = f.pty_id
       AND aa.corp_org = f.corp_org
       AND f.start_dt <= to_date('2014-03-31', 'YYYY-MM-DD')
       AND f.end_dt > to_date('2014-03-31', 'YYYY-MM-DD') 
       where   bb.MAX_DATE < to_date( '2014-03-01', 'YYYY-MM-DD')
       and aa.card_open_org in (SELECT t.Org_Id
                               FROM b_m_Sys_Branch t
                              WHERE t.Status = 1
                                AND t.Dept_Flag != '2'
                             CONNECT BY  PRIOR t.Id = t.Parent_Id
                              START WITH t.Org_Id =10000) ;
                              
                              
                              select * from table(dbms_xplan.display());
    Plan hash value: 4046975539
     
    -------------------------------------------------------------------------------------------------------------------------
    | Id  | Operation                                       | Name                  | Rows  | Bytes | Cost (%CPU)| Time     |
    -------------------------------------------------------------------------------------------------------------------------
    |   0 | SELECT STATEMENT                                |                       |    21 |  5040 |   267K  (2)| 00:53:36 |
    |   1 |  NESTED LOOPS OUTER                             |                       |    21 |  5040 |   267K  (2)| 00:53:36 |
    |   2 |   NESTED LOOPS OUTER                            |                       |     6 |  1266 |   267K  (2)| 00:53:36 |
    |*  3 |    HASH JOIN                                    |                       |     6 |   900 |   267K  (2)| 00:53:36 |
    |*  4 |     HASH JOIN                                   |                       |     6 |   660 |   179K  (2)| 00:35:56 |
    |   5 |      VIEW                                       | VW_NSO_1              |     6 |   162 |     4  (25)| 00:00:01 |
    |   6 |       HASH UNIQUE                               |                       |     6 |   294 |     4  (25)| 00:00:01 |
    |*  7 |        FILTER                                   |                       |       |       |            |          |
    |*  8 |         CONNECT BY NO FILTERING WITH SW (UNIQUE)|                       |       |       |            |          |
    |   9 |          TABLE ACCESS FULL                      | B_M_SYS_BRANCH        |   144 |  2880 |     3   (0)| 00:00:01 |
    |  10 |      VIEW                                       |                       |    28 |  2324 |   179K  (2)| 00:35:56 |
    |* 11 |       FILTER                                    |                       |       |       |            |          |
    |  12 |        HASH GROUP BY                            |                       |    28 |  5908 |   179K  (2)| 00:35:56 |
    |* 13 |         HASH JOIN                               |                       |   552 |   113K|   179K  (2)| 00:35:56 |
    |* 14 |          HASH JOIN                              |                       |  2835 |   260K|   110K  (3)| 00:22:10 |
    |  15 |           VIEW                                  |                       |  2805 |   117K|   107K  (3)| 00:21:32 |
    |* 16 |            FILTER                               |                       |       |       |            |          |
    |  17 |             HASH GROUP BY                       |                       |  2805 |   142K|   107K  (3)| 00:21:32 |
    |* 18 |              TABLE ACCESS FULL                  | F_AGT_SAVB_ACCTINFO_H |  8624K|   427M|   107K  (2)| 00:21:25 |
    |* 19 |           TABLE ACCESS FULL                     | F_AGT_CADB_ACCT       | 38498 |  1917K|  3128   (1)| 00:00:38 |
    |* 20 |          TABLE ACCESS FULL                      | F_AGT_CADB_BOOK_H     | 61287 |  7002K| 68898   (2)| 00:13:47 |
    |  21 |     VIEW                                        |                       | 13290 |   519K| 88273   (2)| 00:17:40 |
    |* 22 |      FILTER                                     |                       |       |       |            |          |
    |  23 |       HASH GROUP BY                             |                       | 13290 |   337K| 88273   (2)| 00:17:40 |
    |* 24 |        TABLE ACCESS FULL                        | F_EVT_CADJ_JOUR       |    12M|   298M| 87422   (1)| 00:17:30 |
    |* 25 |    TABLE ACCESS BY INDEX ROWID                  | F_PTY_TABLE           |     1 |    61 |     3   (0)| 00:00:01 |
    |* 26 |     INDEX RANGE SCAN                            | SYS_C0061472          |     1 |       |     2   (0)| 00:00:01 |
    |  27 |   VIEW PUSHED PREDICATE                         | V_M_PTY_EMP_INFO      |     3 |    87 |     4   (0)| 00:00:01 |
    |* 28 |    HASH JOIN OUTER                              |                       |     3 |   153 |   122   (2)| 00:00:02 |
    |* 29 |     TABLE ACCESS BY INDEX ROWID                 | F_PTY_EMP_INFO        |     3 |    99 |     4   (0)| 00:00:01 |
    |* 30 |      INDEX RANGE SCAN                           | EMP_IDX_002           |     3 |       |     1   (0)| 00:00:01 |
    |* 31 |     VIEW                                        |                       | 24404 |   428K|   118   (2)| 00:00:02 |
    |* 32 |      HASH JOIN RIGHT OUTER                      |                       | 24404 |  1406K|   118   (2)| 00:00:02 |
    |* 33 |       TABLE ACCESS FULL                         | B_M_SYS_BRANCH        |    36 |   504 |     3   (0)| 00:00:01 |
    |* 34 |       TABLE ACCESS FULL                         | B_M_SYS_BRANCH        |     1 |    11 |     3   (0)| 00:00:01 |
    |  35 |       VIEW                                      |                       | 24404 |  1072K|   115   (2)| 00:00:02 |
    |* 36 |        HASH JOIN RIGHT OUTER                    |                       | 24404 |  2049K|   115   (2)| 00:00:02 |
    |* 37 |         TABLE ACCESS FULL                       | B_M_SYS_BRANCH        |    36 |   504 |     3   (0)| 00:00:01 |
    |* 38 |         TABLE ACCESS FULL                       | B_M_SYS_BRANCH        |     1 |    11 |     3   (0)| 00:00:01 |
    |  39 |         VIEW                                    |                       | 24404 |  1715K|   111   (1)| 00:00:02 |
    |* 40 |          HASH JOIN RIGHT OUTER                  |                       | 24404 |  1882K|   111   (1)| 00:00:02 |
    |* 41 |           TABLE ACCESS FULL                     | B_M_SYS_BRANCH        |    36 |   504 |     3   (0)| 00:00:01 |
    |* 42 |           HASH JOIN RIGHT OUTER                 |                       | 24404 |  1549K|   108   (1)| 00:00:02 |
    |  43 |            TABLE ACCESS FULL                    | B_M_SYS_BRANCH        |   144 |  1008 |     3   (0)| 00:00:01 |
    |* 44 |            HASH JOIN RIGHT OUTER                |                       | 24404 |  1382K|   105   (1)| 00:00:02 |
    |  45 |             VIEW                                | M_CBS_TO_DW_ORG       |   141 |  4794 |     8   (0)| 00:00:01 |
    |  46 |              UNION-ALL                          |                       |       |       |            |          |
    |* 47 |               TABLE ACCESS FULL                 | F_PTY_ORG             |   127 |  2794 |     5   (0)| 00:00:01 |
    |* 48 |               TABLE ACCESS FULL                 | B_M_SYS_BRANCH        |    14 |    98 |     3   (0)| 00:00:01 |
    |* 49 |             TABLE ACCESS FULL                   | F_PTY_EMP_INFO        | 24404 |   571K|    97   (2)| 00:00:02 |
    -------------------------------------------------------------------------------------------------------------------------
     
    Predicate Information (identified by operation id):
    ---------------------------------------------------
     
       3 - access("AA"."AGMT_ID"="BB"."TRAN_CARD_NO")
       4 - access("AA"."CARD_OPEN_ORG"="ORG_ID")
       7 - filter("T"."STATUS"=1 AND "T"."DEPT_FLAG"<>'2')
       8 - access("T"."PARENT_ID"=PRIOR "T"."ID")
           filter(TO_NUMBER("T"."ORG_ID")=10000)
      11 - filter(SUM("C"."ACCT_BAL")<10)
      13 - access("A"."MASTER_CARD_NO"="AGMT_ID")
      14 - access("ACCT_NO"="C"."AGMT_ID")
      16 - filter(MAX("LAST_TRANS_DATE")<TO_DATE(' 2014-03-01 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  SUM("ACCT_BAL") IS NOT NULL)
      18 - filter("ACCT_STATUS"<>'1' AND "END_DT">TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  "START_DT"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      19 - filter(SUBSTR("ACCT_STATUS",8,1)<>'2')
      20 - filter(SUBSTR("A"."HOST_CARD_STATUS",8,1)='0' AND "A"."MASTER_CARD_NO" IS NOT NULL AND 
                  "A"."END_DT">TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND "A"."START_DT"<=TO_DATE(' 2014-03-31 
                  00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      22 - filter(MAX("XX"."TRANS_DATE")<TO_DATE(' 2014-03-01 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      24 - filter("TRANS_DATE"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      25 - filter("F"."END_DT"(+)>TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      26 - access("AA"."CUST_NO"="F"."PTY_ID"(+) AND "AA"."CORP_ORG"="F"."CORP_ORG"(+) AND 
                  "F"."START_DT"(+)<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
           filter("F"."START_DT"(+)<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  "AA"."CORP_ORG"="F"."CORP_ORG"(+))
      28 - access("T"."START_DT"="B"."START_DT"(+) AND "T"."SOURCE_CODE"="B"."SOURCE_CODE"(+) AND 
                  "T"."PTY_ID"="B"."PTY_ID"(+))
      29 - filter("T"."END_DT">TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  "T"."START_DT"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      30 - access("T"."PTY_ID"="AA"."CUST_MAGR")
      31 - filter("B"."PTY_ID"(+)="AA"."CUST_MAGR" AND "B"."START_DT"(+)<=TO_DATE(' 2014-03-31 00:00:00', 
                  'syyyy-mm-dd hh24:mi:ss'))
      32 - access("FST"."SEC_ORG_ID"="ORG_ID"(+))
      33 - filter("ORG_LEVEL"(+)=2)
      34 - filter("ID"=:B1)
      36 - access("ORG_ID"(+)=NVL("SEC"."THD_ORG_ID","SEC"."ORG_ID"))
      37 - filter("ORG_LEVEL"(+)=3)
      38 - filter("ID"=:B1)
      40 - access("C"."ORG_ID"="ORG_ID"(+))
      41 - filter("ORG_LEVEL"(+)=4)
      42 - access("B"."ORG_ID"="C"."ORG_ID"(+))
      44 - access("A"."ORG_NO"="B"."PTY_ID"(+))
      47 - filter("END_DT"=TO_DATE(' 2999-12-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      48 - filter("ORG_ID" LIKE '%8888%' AND "ORG_ID" IS NOT NULL AND "ORG_ID" IS NOT NULL OR "ORG_ID" LIKE '%9999%' 
                  AND "ORG_ID" IS NOT NULL AND "ORG_ID" IS NOT NULL)
      49 - filter("A"."START_DT"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
    
    
    
    添加hints后;
    explain plan for 
    with aa as
     (select 
             a.agmt_id,
             sum(c.acct_bal) as card_bal, --借记卡期末存款余额
             a.card_open_org,
             a.OPEN_DATE, -- 发卡日期     
             a.CARD_NEW_STATUS, -- 卡片状态    
             a.cust_magr, -- 客户经理号 
             a.cust_no, -- 客户号
             a.corp_org
        from dwf.f_agt_cadb_book_h a
        left outer join (select agmt_id, acct_no
                          from dwf.f_agt_cadb_acct
                         where substr(acct_status, 8, 1) <> '2') b
          on a.master_card_no = b.agmt_id
      
        left outer join (select agmt_id, max(last_trans_date) last_trans_date, sum(acct_bal) acct_bal
                          from dwf.F_AGT_SAVB_ACCTINFO_H
                         where start_dt <= to_date('2014-03-31', 'YYYY-MM-DD')
                           and end_dt > to_date('2014-03-31', 'YYYY-MM-DD')
                           and acct_status <> '1'
                           group by  agmt_id
                           
                           ) c  -- 一卡多账号,某一账号睡眠其它未睡 ,卡账务信息表最后交易日期不准
          on b.acct_no = c.agmt_id
       where substr(a.host_card_status, 8, 1) = '0' --卡状态不为注销
         and a.master_card_no is not null --剔除待领卡
         and a.start_dt <= to_date('2014-03-31', 'YYYY-MM-DD') /*参数传入 季末日期*/
         and a.end_dt > to_date('2014-03-31', 'YYYY-MM-DD') /*参数传入 季末日期*/
         and c.LAST_TRANS_DATE < to_date( '2014-03-01', 'YYYY-MM-DD') /*参数传入 季末日期*/
         and c.acct_bal is not null
       group by a.agmt_id,
                a.card_open_org,
                a.OPEN_DATE, -- 发卡日期     
                a.CARD_NEW_STATUS, -- 卡片状态    
                a.cust_magr, -- 客户经理号  
                a.cust_no, -- 客户号
                a.corp_org
      having(sum(c.acct_bal) < 10)),
    
    bb as
     (SELECT xx.tran_card_no, count(1) cnt, max(xx.trans_date) max_date
        FROM DWF.F_EVT_CADJ_JOUR xx
       WHERE TRANS_DATE <= to_date('2014-03-31', 'YYYY-MM-DD')
       group by xx.tran_card_no)
       
       select /*+use_hash(AA XX) use_hash(AA F)*/ aa.agmt_id, -- 卡号        
           'J' AS CARD_T, -- 卡种类      
           f.pty_name, -- 客户姓名    
           aa.cust_no, -- 客户证件号  
           f.mobile_no, -- 客户手机号  
           aa.OPEN_DATE, -- 发卡日期    
           null as ACTIVEDAY, -- 激活日期    
           aa.CARD_NEW_STATUS, -- 卡片状态    
           to_date('2014-03-31', 'YYYY-MM-DD') - nvl(bb.MAX_DATE, aa.OPEN_DATE) as sleep_day, -- 睡眠时间    
           card_bal, -- 存款余额    
           null as cred_limit, -- 授信额度    
           bb.cnt, -- 交易次数    
           aa.cust_magr, -- 客户经理号  
           xx.emp_name, -- 客户经理名称
           aa.card_open_org, -- 所属机构  
           bb.MAX_DATE
      from aa
      left join bb
        on aa.agmt_id = bb.tran_card_no
      LEFT JOIN dwm.v_m_pty_emp_info xx --员工表
        ON aa.cust_magr = xx.pty_id
       AND xx.start_dt <= to_date('2014-03-31', 'YYYY-MM-DD')
       AND xx.end_dt > to_date('2014-03-31', 'YYYY-MM-DD')
      LEFT JOIN dwf.f_pty_table f --当事人主表
        ON aa.cust_no = f.pty_id
       AND aa.corp_org = f.corp_org
       AND f.start_dt <= to_date('2014-03-31', 'YYYY-MM-DD')
       AND f.end_dt > to_date('2014-03-31', 'YYYY-MM-DD') 
       where   bb.MAX_DATE < to_date( '2014-03-01', 'YYYY-MM-DD')
       and aa.card_open_org in (SELECT t.Org_Id
                               FROM b_m_Sys_Branch t
                              WHERE t.Status = 1
                                AND t.Dept_Flag != '2'
                             CONNECT BY  PRIOR t.Id = t.Parent_Id
                              START WITH t.Org_Id =10000) ;
                             
    Plan hash value: 942330274
     
    -------------------------------------------------------------------------------------------------------------------------
    | Id  | Operation                                       | Name                  | Rows  | Bytes | Cost (%CPU)| Time     |
    -------------------------------------------------------------------------------------------------------------------------
    |   0 | SELECT STATEMENT                                |                       |    21 |  5607 |   272K  (2)| 00:54:34 |
    |*  1 |  HASH JOIN OUTER                                |                       |    21 |  5607 |   272K  (2)| 00:54:34 |
    |*  2 |   HASH JOIN OUTER                               |                       |     6 |  1266 |   272K  (2)| 00:54:31 |
    |*  3 |    HASH JOIN                                    |                       |     6 |   900 |   267K  (2)| 00:53:36 |
    |*  4 |     HASH JOIN                                   |                       |     6 |   660 |   179K  (2)| 00:35:56 |
    |   5 |      VIEW                                       | VW_NSO_1              |     6 |   162 |     4  (25)| 00:00:01 |
    |   6 |       HASH UNIQUE                               |                       |     6 |   294 |     4  (25)| 00:00:01 |
    |*  7 |        FILTER                                   |                       |       |       |            |          |
    |*  8 |         CONNECT BY NO FILTERING WITH SW (UNIQUE)|                       |       |       |            |          |
    |   9 |          TABLE ACCESS FULL                      | B_M_SYS_BRANCH        |   144 |  2880 |     3   (0)| 00:00:01 |
    |  10 |      VIEW                                       |                       |    28 |  2324 |   179K  (2)| 00:35:56 |
    |* 11 |       FILTER                                    |                       |       |       |            |          |
    |  12 |        HASH GROUP BY                            |                       |    28 |  5908 |   179K  (2)| 00:35:56 |
    |* 13 |         HASH JOIN                               |                       |   552 |   113K|   179K  (2)| 00:35:56 |
    |* 14 |          HASH JOIN                              |                       |  2835 |   260K|   110K  (3)| 00:22:10 |
    |  15 |           VIEW                                  |                       |  2805 |   117K|   107K  (3)| 00:21:32 |
    |* 16 |            FILTER                               |                       |       |       |            |          |
    |  17 |             HASH GROUP BY                       |                       |  2805 |   142K|   107K  (3)| 00:21:32 |
    |* 18 |              TABLE ACCESS FULL                  | F_AGT_SAVB_ACCTINFO_H |  8624K|   427M|   107K  (2)| 00:21:25 |
    |* 19 |           TABLE ACCESS FULL                     | F_AGT_CADB_ACCT       | 38498 |  1917K|  3128   (1)| 00:00:38 |
    |* 20 |          TABLE ACCESS FULL                      | F_AGT_CADB_BOOK_H     | 61287 |  7002K| 68898   (2)| 00:13:47 |
    |  21 |     VIEW                                        |                       | 13290 |   519K| 88273   (2)| 00:17:40 |
    |* 22 |      FILTER                                     |                       |       |       |            |          |
    |  23 |       HASH GROUP BY                             |                       | 13290 |   337K| 88273   (2)| 00:17:40 |
    |* 24 |        TABLE ACCESS FULL                        | F_EVT_CADJ_JOUR       |    12M|   298M| 87422   (1)| 00:17:30 |
    |* 25 |    TABLE ACCESS FULL                            | F_PTY_TABLE           |   704K|    40M|  4632   (1)| 00:00:56 |
    |  26 |   VIEW                                          | V_M_PTY_EMP_INFO      | 24388 |  1333K|   215   (2)| 00:00:03 |
    |* 27 |    HASH JOIN RIGHT OUTER                        |                       | 24388 |  1214K|   215   (2)| 00:00:03 |
    |  28 |     VIEW                                        |                       | 24404 |   428K|   118   (2)| 00:00:02 |
    |* 29 |      HASH JOIN RIGHT OUTER                      |                       | 24404 |  1406K|   118   (2)| 00:00:02 |
    |* 30 |       TABLE ACCESS FULL                         | B_M_SYS_BRANCH        |    36 |   504 |     3   (0)| 00:00:01 |
    |* 31 |       TABLE ACCESS FULL                         | B_M_SYS_BRANCH        |     1 |    11 |     3   (0)| 00:00:01 |
    |  32 |       VIEW                                      |                       | 24404 |  1072K|   115   (2)| 00:00:02 |
    |* 33 |        HASH JOIN RIGHT OUTER                    |                       | 24404 |  2049K|   115   (2)| 00:00:02 |
    |* 34 |         TABLE ACCESS FULL                       | B_M_SYS_BRANCH        |    36 |   504 |     3   (0)| 00:00:01 |
    |* 35 |         TABLE ACCESS FULL                       | B_M_SYS_BRANCH        |     1 |    11 |     3   (0)| 00:00:01 |
    |  36 |         VIEW                                    |                       | 24404 |  1715K|   111   (1)| 00:00:02 |
    |* 37 |          HASH JOIN RIGHT OUTER                  |                       | 24404 |  1882K|   111   (1)| 00:00:02 |
    |* 38 |           TABLE ACCESS FULL                     | B_M_SYS_BRANCH        |    36 |   504 |     3   (0)| 00:00:01 |
    |* 39 |           HASH JOIN RIGHT OUTER                 |                       | 24404 |  1549K|   108   (1)| 00:00:02 |
    |  40 |            TABLE ACCESS FULL                    | B_M_SYS_BRANCH        |   144 |  1008 |     3   (0)| 00:00:01 |
    |* 41 |            HASH JOIN RIGHT OUTER                |                       | 24404 |  1382K|   105   (1)| 00:00:02 |
    |  42 |             VIEW                                | M_CBS_TO_DW_ORG       |   141 |  4794 |     8   (0)| 00:00:01 |
    |  43 |              UNION-ALL                          |                       |       |       |            |          |
    |* 44 |               TABLE ACCESS FULL                 | F_PTY_ORG             |   127 |  2794 |     5   (0)| 00:00:01 |
    |* 45 |               TABLE ACCESS FULL                 | B_M_SYS_BRANCH        |    14 |    98 |     3   (0)| 00:00:01 |
    |* 46 |             TABLE ACCESS FULL                   | F_PTY_EMP_INFO        | 24404 |   571K|    97   (2)| 00:00:02 |
    |* 47 |     TABLE ACCESS FULL                           | F_PTY_EMP_INFO        | 24349 |   784K|    97   (2)| 00:00:02 |
    -------------------------------------------------------------------------------------------------------------------------
     
    Predicate Information (identified by operation id):
    ---------------------------------------------------
     
       1 - access("AA"."CUST_MAGR"="XX"."PTY_ID"(+))
       2 - access("AA"."CORP_ORG"="F"."CORP_ORG"(+) AND "AA"."CUST_NO"="F"."PTY_ID"(+))
       3 - access("AA"."AGMT_ID"="BB"."TRAN_CARD_NO")
       4 - access("AA"."CARD_OPEN_ORG"="ORG_ID")
       7 - filter("T"."STATUS"=1 AND "T"."DEPT_FLAG"<>'2')
       8 - access("T"."PARENT_ID"=PRIOR "T"."ID")
           filter(TO_NUMBER("T"."ORG_ID")=10000)
      11 - filter(SUM("C"."ACCT_BAL")<10)
      13 - access("A"."MASTER_CARD_NO"="AGMT_ID")
      14 - access("ACCT_NO"="C"."AGMT_ID")
      16 - filter(MAX("LAST_TRANS_DATE")<TO_DATE(' 2014-03-01 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  SUM("ACCT_BAL") IS NOT NULL)
      18 - filter("ACCT_STATUS"<>'1' AND "END_DT">TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  "START_DT"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      19 - filter(SUBSTR("ACCT_STATUS",8,1)<>'2')
      20 - filter(SUBSTR("A"."HOST_CARD_STATUS",8,1)='0' AND "A"."MASTER_CARD_NO" IS NOT NULL AND 
                  "A"."END_DT">TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND "A"."START_DT"<=TO_DATE(' 2014-03-31 
                  00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      22 - filter(MAX("XX"."TRANS_DATE")<TO_DATE(' 2014-03-01 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      24 - filter("TRANS_DATE"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      25 - filter("F"."END_DT"(+)>TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  "F"."START_DT"(+)<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      27 - access("T"."START_DT"="B"."START_DT"(+) AND "T"."SOURCE_CODE"="B"."SOURCE_CODE"(+) AND 
                  "T"."PTY_ID"="B"."PTY_ID"(+))
      29 - access("FST"."SEC_ORG_ID"="ORG_ID"(+))
      30 - filter("ORG_LEVEL"(+)=2)
      31 - filter("ID"=:B1)
      33 - access("ORG_ID"(+)=NVL("SEC"."THD_ORG_ID","SEC"."ORG_ID"))
      34 - filter("ORG_LEVEL"(+)=3)
      35 - filter("ID"=:B1)
      37 - access("C"."ORG_ID"="ORG_ID"(+))
      38 - filter("ORG_LEVEL"(+)=4)
      39 - access("B"."ORG_ID"="C"."ORG_ID"(+))
      41 - access("A"."ORG_NO"="B"."PTY_ID"(+))
      44 - filter("END_DT"=TO_DATE(' 2999-12-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      45 - filter("ORG_ID" LIKE '%8888%' AND "ORG_ID" IS NOT NULL AND "ORG_ID" IS NOT NULL OR "ORG_ID" LIKE '%9999%' 
                  AND "ORG_ID" IS NOT NULL AND "ORG_ID" IS NOT NULL)
      46 - filter("A"."START_DT"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
      47 - filter("T"."END_DT">TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss') AND 
                  "T"."START_DT"<=TO_DATE(' 2014-03-31 00:00:00', 'syyyy-mm-dd hh24:mi:ss'))
                              
    

  • 相关阅读:
    实验三-并发程序 20175201张驰
    20175201 20175215 20175229 实验二 固件程序设计
    20175201 20175215 20175229 实验一 开发环境的熟悉
    #20175201 实验五 网络编程与安全
    云班课选做
    2019-2020-12 20175313 20175328 20175329 实验五 通讯协议设计
    2019-2020-1 20175313 20175328 20175329 实验四 外设驱动程序设计
    2019-2020-1 20175313 20175328 20175329 实验三 并发程序
    20175329&20175313&20175318 2019-2020 《信息安全系统设计基础》实验三
    20175329&20175313&20175318 2019-2020 《信息安全系统设计基础》实验二
  • 原文地址:https://www.cnblogs.com/zhaoyangjian724/p/3797877.html
Copyright © 2020-2023  润新知