Problem with predicate of CAE

Hello
I just started know CAE and spin a question with a very simple example. I have a local database on my machine with Figure 2: OLTP and OLAP. I create a context service policy etc. in the OLTP schema, I connect to the other OLAP schema and then I do a

Select * from w_case_d, the results are not filtered.

I'm looking at v$ vpd_policy and the predicate field is null.
Can you help me determine what I am doing wrong? Thank you for your time.

Frank


Details
------

CREATE OR REPLACE CONTEXT WITH THE HELP OF INITIALIZATION_PROCEDURE VPD_CONTEXT;
/

create or replace procedure initialization_procedure
(
v_user in varchar2
)
is
Start
DBMS_SESSION.set_Context ('VPD_CONTEXT', 'USER_NAME', v_user);
end initialization_procedure;
/

create or replace function initialization_function (v_user in varchar2)
VARCHAR2 is back
Start
initialization_procedure (v_user);
SYS_CONTEXT ('VPD_CONTEXT', 'USER_NAME') return;
end;
/

create or replace FUNCTION apply_policy)
p_schema IN VARCHAR2,
p_object IN VARCHAR2)
RETURN VARCHAR2
AS
v_stmt varchar2 (500);

BEGIN
v_stmt: = 'ETL_PROC_WID = 368';
Return v_stmt;
END;
/

BEGIN
DBMS_RLS.add_policy
(object_schema = > "OLAP")
object_name = > "W_CASE_D"
POLICY_NAME = > "test_policy"
function_schema = > 'OLTP.
policy_function = > 'apply_policy ',.
statement_types = > 'SELECT');
END;

Is the EXEMPT STRATEGY of access granted OLAP schema?

Tags: Database

Similar Questions

  • Problem with predicate

    Hi, I'm really frustrated with something, if someone could help I would really appreciate it.

    I have a table where I'm trying to select some records

    SELECT DISTINCT Major_status,
    minor_status
    MIND;

    MAJOR_STATUS MINOR_STATUS
    ------------ ------------
    50 0
    30 0
    60 270
    3 80
    60 0
    60 200
    30 270


    I want to select all records except those with a 60 major_status and a 200 minor_status

    SELECT DISTINCT Major_status,
    minor_status
    MIND
    WHERE minor_status! = 200
    AND major_status! = 60;

    MAJOR_STATUS MINOR_STATUS
    ------------ ------------
    50 0
    30 0
    3 80
    30 270

    4 selected lines.

    In the above query, I expect to see additional lines

    MAJOR_STATUS MINOR_STATUS
    ------------ ------------
    60 270
    60 0

    as they do not have a minor status of 200. I can't work on why they don't come through.

    With the help of 10g R2

    Thank you very much

    T
    SELECT DISTINCT major_status,
    minor_status
    FROM header
    WHERE not(minor_status = 200
    AND major_status = 60)
    

    It may be easy to understand if it's like that

    Ravi Kumar

  • Problem of predicate push with views

    Hi guys,.

    I had a fairly long discussion to this thread - Re: One - a database - different execution plan for various users. -on a problem I encounter in 11g.  After a lot of work, we were able to reduce the problem to what seems to be a problem of predicate push when using views but not tables.

    To summarize the question, I have a user who has a bunch of tables and a layer of views that are based on tables (select * from table_name) that we use to manage access and create a layer of insulation of the tables.  All users (other than the owner) will have to choose against the views.  Unfortunately what we see is that when they use the perspective to make the choice, they get terrible performance where if they use the tables, they get the performance.  Here's a simple query which documents the problem.

    GOOD QUERY

    SQL > set timing on
    SQL > set linesize 160
    SQL > set serveroutput off
    SQL >
    SQL > select / * + gather_plan_statistics * /.
    2 w.worker_id, w.worker_name
    tas.worker_tbl 3 w,
    TAS.worker_cost_centre_tbl 4 c
    5 where w.worker_id = c.worker_id
    6 and c.effective_date < = trunc (sysdate)
    7 and c.expiration_date > = trunc (sysdate)
    8 and c.cost_centre = '100033'
    9 and tas_user.pkg_taw_security.user_worker_access ('CA17062',
    10                                             'TIMEKEEPER',
    11                                             w.worker_id,
    12 trunc (sysdate)) = 1
    13. in order to w.worker_name;

    WORKER_ID WORKER_NAME
    --------- ------------------------------------------------------------------------------------------
    123703 FADDEN, CLAYTON
    11131 HAHN, BRAD
    33811 HALL, MAUREEN
    53934 JANES, CATHERINE

    Elapsed time: 00:00:00.02
    SQL >
    SQL > select * from table (dbms_xplan.display_cursor (null, null, 'ALLSTATS LAST'));

    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------
    SQL_ID, 3np2s1wpqxnpu, number of children 1
    -------------------------------------
    Select / * + gather_plan_statistics * / w.worker_id, w.worker_name
    of tas.worker_tbl w.
    c tas.worker_cost_centre_tbl where w.worker_id = c.worker_id
    and c.effective_date < = trunc (sysdate) and c.expiration_date > =
    trunc (sysdate) and c.cost_centre = '100033' and
    tas_user.pkg_taw_security.user_worker_access ('CA17062',
    "TIMEKEEPER"
    w.worker_id,
    trunc (sysdate)) = 1 order by w.worker_name

    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------

    Hash value of plan: 3435904055

    ----------------------------------------------------------------------------------------------------
    | ID | Operation | Name                   | Begins | E - lines. A - lines.   A - time | Pads |  OMem |  1Mem |
    ----------------------------------------------------------------------------------------------------
    |   0 | SELECT STATEMENT |                        |      1.        |      4. 00:00:00.01 |     185.       |       |          |
    |   1.  SORT ORDER BY |                        |      1.      4.      4. 00:00:00.01 |     185.  2048 |  2048 | 2048
    |   2.   NESTED LOOPS |                        |      1.        |      4. 00:00:00.01 |     185.       |       |          |
    |   3.    NESTED LOOPS |                        |      1.      4.      4. 00:00:00.01 |     181.       |       |          |
    |*  4 |     TABLE ACCESS BY INDEX ROWID | WORKER_COST_CENTRE_TBL |      1.      4.      4. 00:00:00.01 |

    |*  5 |      INDEX RANGE SCAN | WORKER_CC_CC_IDX |      1.     29.     21. 00:00:00.01 |       3.
    |*  6 |     INDEX UNIQUE SCAN | WORKER_PK |      4.      1.      4. 00:00:00.01 |     163.       |       |
    |   7.    TABLE ACCESS BY INDEX ROWID | WORKER_TBL |      4.      1.      4. 00:00:00.01 |       4.       |       |
    ----------------------------------------------------------------------------------------------------

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

    4 - filter("C".") (Correspondents' > = TRUNC(SYSDATE@!))
    5 - access("C".") COST_CENTRE "="100033"AND 'C'." (EFFECTIVE_DATE"< = TRUNC(SYSDATE@!))
    6 - access("W".") WORKER_ID "=" C ". ("' WORKER_ID")

    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------
    filter ("PKG_TAW_SECURITY". "USER_WORKER_ACCESS"('CA17062', 'CHRONOMÉTREUR","W".») WORKER_ID «, TRUNC (S)»

    Note
    -----
    -Comments of cardinality used for this statement


    39 selected lines.

    Elapsed time: 00:00:00.05

    So, that's the good thing - it did exactly what I expected it hits the Worker_CC_CC_IDX to get the workers who belong to a cost center and then hit the worker_PK to get their names.  In the end, it applies the filter that validates that the user running the application has access to the worker in question through safety.

    BAD REQUEST

    SQL > set linesize 160
    SQL > set serveroutput off
    SQL >
    SQL > select / * + gather_plan_statistics * /.
    2 w.worker_id, w.worker_name
    tas.worker_v 3 w,
    TAS.worker_cost_centre_v 4 c
    5 where w.worker_id = c.worker_id
    6 and c.effective_date < = trunc (sysdate)
    7 and c.expiration_date > = trunc (sysdate)
    8 and c.cost_centre = '100033'
    9 and tas_user.pkg_taw_security.user_worker_access ('CA17062',
    10                                             'TIMEKEEPER',
    11                                             w.worker_id,
    12 trunc (sysdate)) = 1
    13. in order to w.worker_name;

    WORKER_ID WORKER_NAME
    --------- ------------------------------------------------------------------------------------------
    123703 FADDEN, CLAYTON
    11131 HAHN, BRAD
    33811 HALL, MAUREEN
    53934 JANES, CATHERINE

    Elapsed time: 00:00:18.05
    SQL >
    SQL > select * from table (dbms_xplan.display_cursor (null, null, 'ALLSTATS LAST'));

    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------
    SQL_ID, gs5vtgany8vbv, number of children 1
    -------------------------------------
    Select / * + gather_plan_statistics * / w.worker_id, w.worker_name
    of tas.worker_v w, tas.worker_cost_centre_v
    c where w.worker_id = c.worker_id and c.effective_date < =.
    trunc (sysdate) and c.expiration_date > = trunc (sysdate) and
    c.cost_centre = '100033' and tas_user.pkg_taw_security.user_worker_ac
    Cess ('CA17062',
    "TIMER", w.worker_id,
    trunc (sysdate)) = 1 order by
    w.worker_name

    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------

    Hash value of plan: 1726112176

    ----------------------------------------------------------------------------------------------------
    | ID | Operation | Name                   | Begins | E - lines. A - lines.   A - time | Pads |  OMem |  1Mem |
    ----------------------------------------------------------------------------------------------------
    |   0 | SELECT STATEMENT |                        |      1.        |      4. 00:00:18.26 |     947K |       |       |          |
    |   1.  SORT ORDER BY |                        |      1.      4.      4. 00:00:18.26 |     947K |  2048 |  2048 | 2048
    |*  2 |   HASH JOIN |                        |      1.      4.      4. 00:00:14.28 |     947K |  1348K |  1348K |  546K (0)
    |   3.    VIEW                        | WORKER_COST_CENTRE_V |      1.      4.      4. 00:00:00.01 |      18.       |       |
    |*  4 |     TABLE ACCESS BY INDEX ROWID | WORKER_COST_CENTRE_TBL |      1.      4.      4. 00:00:00.01 |

    |*  5 |      INDEX RANGE SCAN | WORKER_CC_CC_IDX |      1.     29.     21. 00:00:00.01 |       3.
    |*  6 |    VIEW                        | WORKER_V |      1.    161K |      4. 00:00:14.28 |     946K |       |       |          |
    |   7.     TABLE ACCESS FULL | WORKER_TBL |      1.    161K |    160K | 00:00:00.09 |    2135
    ----------------------------------------------------------------------------------------------------

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

    2 - access("W".") WORKER_ID "=" C ". ("' WORKER_ID")
    4 - filter("X".") (Correspondents' > = TRUNC(SYSDATE@!))
    5 - access("X".") COST_CENTRE "="100033"AND 'X'." (EFFECTIVE_DATE"< = TRUNC(SYSDATE@!))

    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------
    6 - filter("PKG_TAW_SECURITY".") USER_WORKER_ACCESS "('CA17062', 'CHRONOMÉTREUR)", "W". "WORKER_ID", TRUNC (S).

    Note
    -----
    -Comments of cardinality used for this statement


    39 selected lines.

    Elapsed time: 00:00:00.05

    So the bad query takes 18 seconds to bring the same answer - but the only change is to the user views instead of tables _TBL _V.  In this case she made a hash out of a table scan join full of the worker_tbl to an analysis of the index of the worker_cost_centre_tbl of course it takes forever in comparison.  The real question is WHY?

    I know that you are going to ask a couple of things - see definitions and synonyms... so here.

    Display definitions

    SQL > select view_name, dba_views text where view_name in ('WORKER_COST_CENTRE_V', 'WORKER_V');

    VIEW_NAME TEXT
    ------------------------------ ---------------------------------------------------------------------
    WORKER_COST_CENTRE_V select x.worker_id,.
    x.effective_date,
    x.expiration_date,
    x.cost_centre
    of worker_cost_centre_tbl x

    WORKER_V select x.worker_id,.
    x.user_id,
    x.last_name,
    x.first_name,
    x.worker_name,
    x.Initials,
    x.Gender,
    x.BIRTH_DATE,
    x.hire_date,
    x.service_date,
    x.badge_created_date,
    x.address_one,
    x.address_two,
    x.city_name,
    x.state_province,
    x.zip_code,
    x.telephone_number,
    x.Email_Address,
    x.ftchip_per_diem_flag,
    x.aip_flag,
    x.hot_change_flag,
    x.pop_flag
    of worker_tbl x

    Thesaurus - public

    SQL > select * from dba_synonyms where synonym_name in ('WORKER_COST_CENTRE_V', 'WORKER_V');

    OWNER SYNONYM_NAME TABLE_OWNER, TABLE_NAME
    ------------------------------ ------------------------------ ------------------------------ -------
    DB_LINK
    ----------------------------------------------------------------------------------------------------
    PUBLIC WORKER_COST_CENTRE_V BUNCH WORKER_COST_CENTRE_V


    PUBLIC WORKER_V BUNCH WORKER_V


    Thesaurus - private

    SQL > select * from user_synonyms where synonym_name in ('WORKER_COST_CENTRE_V', 'WORKER_V');

    no selected line

    So as you can see, the views do nothing in this case - and should not change the query at all in my opinion.

    Deleting the call of all the query - same using views - led to the execution plan.  That's why I think that it is some kind of problem weird predicate push.  I can and that you have captured the query (and the 25 or so similar) to make it work less 11g using the view by using the NO_PUSH_PRED flag and by the query without the security call in a query internal.  Tuning queries is not the problem - the problem is "why should I?  Oracle should use the tables or views in the same way here shouldn't it?  To further complicate things, if I run this same query 'wrong' with points of view as the owner of the tables - it works perfectly.  If I grant it the DBA role to a user, and run the query so bad that this user - it works perfectly.

    Anyone got any ideas what the hell is happening here?

    Thank you
    Cory Aston

    To a large extent, view sure merge is activated to reduce the risk of certain transformations optimizer allows you to reverse scurity functions. It is possible that Oracle didn't closely resembles the view definition or function however to decide if the service could pose a threat if view merger took place.  Christian Antognini has an example on his blog if you want an idea of why the functions of views could be a problem: http://www.antognini.ch/2011/09/optimizer_secure_view_merging-and-vpd/

    A test, you can try:

    ALTER system set optimizer_secure_view_merging = false;

    Concerning

    Jonathan Lewis

    UPDATE: just to change true to FALSE

  • Potential problems with copy_table_stats.

    Guys,

    I have a table with the DDL below containing a huge number of records.

    CREATE TABLE APPEAL. CALL_DTL

    (

    DATE TIME STAMP,

    MSN VARCHAR2 (32 BYTE) NOT NULL,

    EVENT DATE NOT NULL,

    )

    PARTITION BY RANGE (EVENT)

    (

    CALL_P_01122015 PARTITION VALUES LESS THAN (TO_DATE (' 2015-12-01 00:00:00 ',' SYYYY-MM-DD HH24:MI:SS ',' NLS_CALENDAR = GREGORIAN ')),

    CALL_P_02122015 PARTITION VALUES LESS THAN (TO_DATE (' 2015-12-02 00:00:00 ',' SYYYY-MM-DD HH24:MI:SS ',' NLS_CALENDAR = GREGORIAN '))

    CALL_P_03122015 PARTITION VALUES LESS THAN (TO_DATE (' 2015-12-03 00:00:00 ',' SYYYY-MM-DD HH24:MI:SS ',' NLS_CALENDAR = GREGORIAN '))

    );

    We collect statistics for the 1st of the score of the month.

    BEGIN

    DBMS_STATS.gather_table_stats)

    ownname = > 'CALL. "

    tabname = > 'CALL_DTL ',.

    partName = > "CALL_P_01122015"

    estimate_percent = > 1,

    GRANULARITY = > 'APPROX_GLOBAL AND PARTITION,

    Cascade = > TRUE,

    degree = > 15);

    END;

    /

    And the stats will be copied in the rest of the partitions of the month.

    Start

    DBMS_STATS.copy_table_stats (ownname = > 'CALL')

    tabname = > 'PMS_CALL_DETAIL ',.

    srcpartname = > 'CALL_P_01122015 ',.

    dstpartname = > 'CALL_P_02122015');

    end;

    /

    Start

    DBMS_STATS.copy_table_stats (ownname = > 'CALL')

    tabname = > 'PMS_CALL_DETAIL ',.

    srcpartname = > 'CALL_P_01122015 ',.

    dstpartname = > 'CALL_P_03122015');

    end;

    /

    Start

    DBMS_STATS.copy_table_stats (ownname = > 'CALL')

    tabname = > 'PMS_CALL_DETAIL ',.

    srcpartname = > 'CALL_P_01122015 ',.

    dstpartname = > 'CALL_P_04122015');

    end;

    /

    ...

    ...

    Could someone advise if there could be potential problems with the copy of his stats?

    What I see, HIGH_VALUE and LOW_VALUE are the same for every single partition for the SQL below:

    Select nom_partition, HIGH_VALUE, LOW_VALUE from dba_part_col_statistics where table_name = column_name 'CALL' IN ("MSN");


    Will this result in CBO plan fetching suboptimal on SQL running on the table with predicate such as MSN and EVENT?

    Please suggest me resolution approaches.


    Thank you!!


    -Bibi





    It will depend on (among other things), how use you it as a predicate and unique how the column is.

    If you try to filter using predicates of beach in function with a range outside the stats then the CBO will be predicate weak cardinalities and therefore will promote the access of the index and nested loops which leads to this.

    If you are filtering on equality predicates and the key is unique there should be no problem really.

    It will depend also on whether the request knows which partition will be scanned, otherwise it will use global statistics, which will be probably the same as a partition, but they could easily change if you were to collect stats on any other partition.

    You have an environment you can use a test and see approach?

  • problem with loop statement

    Hello

    I'm new in plsql, so I need your help. I am rewriting the existing plpgsql function plsql function, but I have an error on line 15: PLS-00103: encountered the symbol "LOOP" when expecting one of the following values:

    What is the problem with the LOOP statement?

    FUNCTION to CREATE or REPLACE dothework (service_name text string_value)

    RETURNS the text AS

    BEGIN

    DECLARE

    result text;

    varying (31) of tempId character;

    tempFieldId bigint;

    text of tempStringValue;

    tempCount bigint;

    BEGIN

    result = ";

    FOR IN tempId

    SELECT ce.id FROM mfc.card_element this

    WHERE the ce.name AS service_name

    LOOP

    tempCount = 0;

    SELECT INTO tempFieldId mfc.card_field CF field_id

    WHERE cf.field_name = 'NPAname ';

    SELECT INTO tempCount count (*) FROM mfc.card_element_field_value cefv

    WHERE the cefv.card_element_id AS a tempId AND field_id = tempFieldId;

    IF tempCount = 1 THEN

    UPDATE mfc.card_element_field_value

    SET field_string_value = string_value

    WHERE the card_element_id AS a tempId AND field_id = tempFieldId;

    result: = result | tempId | 'UPDATE - YES,';

    ELSIF tempCount = 0 THEN

    INSERT INTO mfc.card_element_field_value (id, field_date_value, field_integer_value, field_string_value, card_element_id, field_id)

    VALUES (HIBERNATE_SEQUENCE.nextval,

    NULL,

    NULL,

    string_value,

    tempId,

    tempFieldId);

    result: = result | tempId | "INSERT - YES, ';

    ON THE OTHER

    result: = result | tempId | "tempCount,";

    END IF;

    -END IF;

    END LOOP;

    RETURN result;

    END;

    END;

    I did the same refatoring I program you unit and put comments to help to understand.

    Let me know if it help you

    FUNCTION to CREATE or REPLACE dothework (service_name in VARCHAR2

    string_value IN VARCHAR2) RETURN VARCHAR2 AS

    -Not necessary to define the new block here BEGIN-

    -SAYS - you only need the instruction stated in this case if you

    -believe that he can raise one exceptional and you want to manage block outsider

    --

    -You must set the buffer of varchar2

    -32767 is the largest amount

    RESULT VARCHAR2 (32767).

    --

    -You can dock this type for the column type, you will receive the data

    tempfieldid card_field.field_id%TYPE;

    -tempstringvalue VARCHAR2; -you do not use this variable

    tempcount NUMBER;

    BEGIN

    -You don't need to initialize with NULL, in this case. PLSQL has done already for you

    -THE RESULT: = ";

    --

    -It seems to me that this request can be outside of the loop

    -Once the table is not the change and the predicate doenst change is

    SELECT field_id

    IN tempfieldid

    Card_field FC

    WHERE cf.field_name = 'NPAname ';

    --

    FOR tempid IN (SELECT ce.id

    OF card_element this

    WHERE the ce.name AS service_name) LOOP

    -It is not necessary to initialize this variable to zero

    -tempcount: = 0;

    --

    --

    SELECT COUNT (*)

    IN tempcount

    OF card_element_field_value cefv

    WHERE the cefv.card_element_id AS a tempid

    AND field_id = tempfieldid;

    --

    IF tempcount = 1 THEN

    UPDATE card_element_field_value

    SET field_string_value = string_value

    WHERE the card_element_id AS a tempid

    AND field_id = tempfieldid;

    RESULT: = RESULT | tempid | 'UPDATE - YES,';

    ELSIF tempcount = 0 THEN

    INSERT INTO card_element_field_value

    (id

    field_date_value

    field_integer_value

    field_string_value

    card_element_id

    field_id)

    VALUES

    (hibernate_sequence.nextval

    NULL

    NULL

    string_value

    tempid

    tempfieldid);

    RESULT: = RESULT | tempid | "INSERT - YES, ';

    ON THE OTHER

    -I remove the tempCount on the "because I think you want to see the number of records

    -you do business with

    RESULT: = RESULT | tempid | ' ' || tempCount | ', ';

    END IF;

    END LOOP;

    RETURN RESULT;

    -END;

    END;

    Best regards

  • Problem with Oracle performance

    Hi all

    I use Oracle database 11 g 2.

    I am facing a problem with one of my queries.


    Scenario is:
    I associate myself with 3 tables.
    The engine is saa_hist.saa_rep_product_activity (70 million lines).
    The second table is scmsa_hist.scmsa_sub_feature_trueup (900 million lines).
    The third table is saa_hist.saa_rep_subscriber_activity (35 million lines).

    The output of the query will be only about 120K.

    I'm majoriy of the columns in the first table. On the other hand, we get 2 columns and in table 3, we get a single column.

    When I join all 3 tables as it appears in the query runs for 6 hours. (The

    SELECT / * + PARALLEL_INDEX(R,SAA_REP_PRODUCT_ACTIVITY_BI,12)
    PARALLEL(SUB,24)
    PARALLEL_INDEX(RR,SAA_REP_SUBSCRIBER_ACTIVITY_I1,8)

    */
    R.*, sub.mrc, sub. RATEPLANCODE, rr.measure_group_id
    Saa_hist.saa_rep_product_activity r
    JOIN scmsa_hist.scmsa_sub_feature_trueup sub
    ON sub.job_log_id = r.job_log_id
    AND sub.service_number = r.msisdn
    AND sub.ban = r.account_number
    AND sub.soc_code = r.product_id_code
    LEFT OUTER JOIN saa_hist.saa_rep_subscriber_activity rr
    ON rr.quantity = 1
    AND rr.service_universal_id = r.service_universal_id
    AND rr.msisdn = r.msisdn
    AND rr.account_number = r.account_number
    WHERE r.billing_subsystem_id = 1
    AND 1 = 1
    AND r.batch_key BETWEEN 674 AND 675;

    The explain command plan looks good for this one and the cost is also okay(222K). I don't see any S-> data flow in the Section of IN-OUT of the explain plan P.

    -----------------------------------------------------------------------------------------------------------------
    | ID | Operation | Name | TQ | IN-OUT | PQ Distrib.
    -----------------------------------------------------------------------------------------------------------------
    | 0 | SELECT STATEMENT |
    | 1. COORDINATOR PX |
    | 2. PX SEND QC (RANDOM). : TQ10001 | Q1, 01 | P > S | QC (RAND) |
    | 3. NESTED EXTERNAL LOOPS | Q1, 01 | SVCP |
    | 4. HASH JOIN | Q1, 01 | SVCP |
    | 5. JOIN FILTER PART CREATE | : BF0000 | Q1, 01 | SVCP |
    | RECEIVE 8 2 PX | Q1, 01 | SVCP |
    | 7. PX SEND LOCAL BROADCAST | : TQ10000 | Q1 00 | P > P | BCST LOCAL |
    | 8. PX HASH PARTITION ALL | Q1 00 | ISSUE |
    | 9. TABLE ACCESS BY LOCAL INDEX ROWID | SAA_REP_PRODUCT_ACTIVITY | Q1 00 | SVCP |
    | 10. CONVERSION OF BITMAP IN ROWID | Q1 00 | SVCP |
    | 11. BITMAP INDEX RANGE SCAN | SAA_REP_PRODUCT_ACTIVITY_BI | Q1 00 | SVCP |
    | 12. FILTER-HASH PARTITION PX JOIN | Q1, 01 | ISSUE |
    | 13. TABLE ACCESS FULL | SCMSA_SUB_FEATURE_TRUEUP | Q1, 01 | SVCP |
    | 14. RANGE OF PARTITION ALL THE | Q1, 01 | SVCP |
    | 15. HASH PARTITION ALL | Q1, 01 | SVCP |
    | 16. TABLE ACCESS BY LOCAL INDEX ROWID | SAA_REP_SUBSCRIBER_ACTIVITY | Q1, 01 | SVCP |
    | 17. INDEX RANGE SCAN | SAA_REP_SUBSCRIBER_ACTIVITY_I1 | Q1, 01 | SVCP |
    -----------------------------------------------------------------------------------------------------------------

    But when I joined the first two tables and run as shown below, the request is get executed in 13 Minutes.

    SELECT / * + PARALLEL_INDEX(R,SAA_REP_PRODUCT_ACTIVITY_BI,12)
    PARALLEL(SUB,24)
    */
    R.*, sub.mrc, sub. RATEPLANCODE, rr.measure_group_id
    Saa_hist.saa_rep_product_activity r
    JOIN scmsa_hist.scmsa_sub_feature_trueup sub
    ON sub.job_log_id = r.job_log_id
    AND sub.service_number = r.msisdn
    AND sub.ban = r.account_number
    AND sub.soc_code = r.product_id_code;

    Therefore, I created a temporary table with this data and made a left outer join with the other 3 table. It runs a few seconds and I can say all the data I am able to take less than 15 minutes to 6 hours.

    So my question is that why Oracle is a strange behavior.

    I tried all approaches to avoid this kind of behavior methods but unable to produce the same thing as how I did in the second approach.

    For example, I joined the first two tables and use NO_MERGE hint with the third table and always NO_MERGE, PUSH_PRED's not going anywhere. I tried Inline view and it doesn't give me any improvement in performance.
    I'm tempted to do it using WITH Clause with two tables and then joined the data set with the third table. But still does not.
    I tried hint ORDINATE and yet so big difference.
    I even tried to force some clues which are presentm, but the 50Million cost ranges from 200K.
    I think I'm exhausted all the possibilities.

    I'd appreciate any Oracle guru can help me what is the issue.

    Thank you
    NKM

    You could start trying to impose (with extensive predicates) what you discover or believe work better.
    In this case I usually found the ansi syntax not useful and often the optimizer ignore my intentions:(mais il n'y a pas de mal essayer)

    select x.*,
           rr.measure_group_id
      from (select r.*
                   sub.mrc,
                   sub.rateplancode,
              from (select *
                      from saa_hist.saa_rep_product_activity
                     where billing_subsystem_id = 1
                       and batch_key between 674 and 675
                   ) r,
                   scmsa_hist.scmsa_sub_feature_trueup sub
             where sub.job_log_id = r.job_log_id
               and sub.service_number = r.msisdn
               and sub.ban = r.account_number
               and sub.soc_code = r.product_id_code
           ) x,
           (select service_universal_id,
                   account_number,
                   msisdn,
                   measure_group_id
              from saa_hist.saa_rep_subscriber_activity
             where quantity = 1
           ) rr
     where x.service_universal_id = rr.service_universal_id(+)
       and x.msisdn = rr.msisdn(+)
       and x.account_number = rr.account_number(+)
    

    Concerning

    Etbin

  • Creating forms on tables with policies of CAE

    Hello

    I have the security infrastructure that involves policies MEV on the tables. When the users are logged on the triggers would set the security context for their session and then EVP allows access to tables.

    Apex allows the same thing using the VPD section in the properties of application security.

    My question is how do I do the same for Apex in build mode. When I try to create the new form based on the table, I get the error in my code VPD indicating that the security session is not initialized, which of course is not like piece VPD in Apex code runs only at run time. So I tried with trigger logon to APEX_PUBLIC_USER but it seems that logon trigger does not fire during application development.

    Is there a solution to my problem?

    The other question is: is it possible to use a DB account for development and one for execution. I guess I could create two entries of Daddy in dads.conf and then use different URLS. Are there problems with it?

    Thank you
    Nenad.

    Nenad salvation,

    Adding another file dads.conf work as long as your policy of the CAE function is a check to make sure will check the current user. For example, in your policy of the CAE function, you can add the following at the beginning:

    IF use = "APEX_DEVELOPMENT_USER" then - assuming that you create this user and reference in the dads.conf
    Returns a null value.
    END IF;
    ....

    You will also need to ensure that the URL that uses the user of development is not accessible to the outside.

    Of course, you could disable VPD on your pattern of development.

    Martin

    -----
    [http://apex-smb.blogspot.com/]

  • problems with, phone, 6, Bluetooth kit, Nissan, after update, for, Rios, 1.0.2

    After the update to ios 10.0.2 - trying to use bluetooth to call my vehicle, it says: "this article is not in your phone book." How can I solve this problem?

    Greetings, joybelino1!

    Thank you for joining the communities Support from Apple! I can't wait to see that you are having problems with your Bluetooth in your car! The good news is that Apple has a great article that will help you with measures to try to resolve the problem. Read this article to gethelp to connect your iPhone, iPad, or iPod touch with your car radio. Even though he talks about problems with the connection, it also has the steps for other questions you may have once connected.

    If you use Bluetooth

    1. Consult the user manual of your car stereo to get the procedure to a Bluetooth device.
    2. On your iOS device, drag up to open Control Center, then press ontwice to turn on Bluetooth and turn it back on.
    3. Restart your iOS device.
    4. On your iOS device, Cancel the twinning of your car radio. On the screen of your car désapparier your iOS device and any other device. Restart your car and your iOS device, then pair and connect again.
    5. Update your iOS device.
    6. Install the updates to the firmware of your car radio.
    7. If you still not connect, contact Apple technical support.

    Have a great day!

  • Anyone having problems with WiFi connectivity after upgrade to Sierra?

    I was wondering if anyone else knows issues with WiFi connectivity since the upgrade to Sierra 10.12? I have not had any problems with connectivity WiFi previously on El Capitan. Now I have regular randomly loose connectivity. My internet is cable and when it is connected I have a 100% connection. My details of iMac and I have used only 10% of my storage.

    No problem with my iphone 6.

    Hello AspDesigns,

    I understand that, since the upgrade to Mac OS Sierra, your Mac seems to have trouble staying connected to Wi - Fi. Fortunately the diagnosis built-in wireless can help identify the source of so much trouble.

    Search for Wi - Fi using your Mac problems

    See you soon!

  • Problems with mail after switching to macOS Sierra

    Hey all

    After having recently upgraded to macOS Sierra, I am unable to read my mail.

    I get the following error every time I check on "Get Mail".

    There may be a problem with the mail server or the network. Check the account settings "*" or try again.

    The server returned the error: Mail could not connect to the server 'pop1.tribcsp.com' using SSL on the default ports. Verify that this server supports SSL and that your account settings are correct.

    What does this error message mean and how can I solve this problem.

    Thank you

    Hi Michael,

    I see your message that you get an error in the mail indicating that there is a problem with the mail server or the network.  To help get this problem resolved, I suggest that you follow the steps below:

    If mail refers to a problem with the mail server, or the network

    Mail will say that it is impossible to connect due to a problem with the mail server or the network. For example, the message may refer to a connection that has expired, or too many simultaneous connections:

    If you are connected to the Internet, but the connection has expired, your email provider might be affected by a discontinuance of service. Contact them or see their status Web page to ensure that their e-mail service is online. Examples of status pages:

    If the message indicates the number of simultaneous connections, too many of your devices is check your e-mail account at the same time. Quit Mail on one or more of your other devices.

    If you are still unable to send or receive e-mails

    1. Make sure that you have installed latest version of the Mac software updates, especially if the problem occurred immediately after the installation of a previous update.
    2. In OS X El Capitan or later version, you can see a status icon and the short error message in the upper right of the Mail window, under the search box. The message may indicate 'Network offline' or 'Connection failed', for example. Click the message to see more details on the issue.
    3. Check your connection to the Mail connection doctor. It might be able to say more on the issue.

    If you cannot send or receive e-mail on your Mac.

    Take care.

  • iMac 27 "mid-2011 - Intermittent problem with CPU fan running at full speed and sleep mode.

    Hello!

    My iMac 27 "has an intermittent problem with the CPU fan runs at full speed. Sometimes it happens at the time when I start it, sometimes only in my session, and sometimes only after a certain time. So does seem to be a problem of "heating".

    Second issue is with the mode 'sleep'. It may occur also at any time, at the start of the iMac, session, or after a certain time. But once he starts to go in mode 'sleep', when I wake up, it goes right back in mode after a few seconds and that it will continue indefinitely until I restart the computer.

    What could be?

    Please help me!

    4ntoine

    Here is my model of iMac:

    iMac 27 "mid-2011 model 12.2

    Intel Core i7 3.4 GHz

    AMD Radeon HD 6970M 1024 MB

    OS X El Capitan 10.11.6
    SMC 1.72f2

    Boot ROM IM121.0047.B23

    reset the SMC

    Reset the management system (SCM) controller on your Mac - Apple Support

  • problem with playing the clash of clans

    I'm having some problems while playing the clash of clans on my 2 mini ipad screen does not seem to meet sometimes as if it was some sort of delay so I have to tap several times in order to use a filter or throw the troops on the battlefield.

    Hi Trinitygr,

    Thanks for posting in the Community Support from Apple! I understand that you are having problems with your iPad screen while playing a game. I like to play games on my iPad and I don't see how this could be a nuisance. I'm happy to offer assistance.

    Are you only had this problem when using the app clash of Clans, or does it happen in all applications? I recommend to start by following the steps described in this article:
    If an application you have installed unexpectedly closes, unresponsive, or does not open

    Take care!

  • I'm having problems with an outdated Apple ID

    I have problems with updating Apps etc in my Apple account because he always asked an obsolete in sign.  How can I change this?

    Hello

    Go down to itunes apple ID Delete page homepage all ID and then add it back back.

    See you soon

    Brian

  • Anyone having problems with the new iPhone LTE connection 7 on Verizon?

    I am now on my iPhone second 7 with Verizon. I had four phones for me and my family. I have now had issues where I have no signal in the same areas where my signal allows to be strong. I can't solve the problem with the activation/deactivation of the airplane and then mode again in normal mode. My phone will rest with no signal for 5 minutes, then going to LTE with three bars. I also had the problem where I had only 1 x signal, while my son standing right next to me has LTE. And he had the same questions, where I'm on LTE and it gets no signal. I use to have LTE where I live and work all the time, now it's spotty at best. Apple has replaced me and my sons iPhones but not luck. Still do. Any ideas or an any other suffering?

    (1) go to settings/cell phone/cellular data Options/enable LTE and select ONLY the DATA. This seems to solve the problem (as a temporary solution) for most of the people affected by this problem. The bad part is your request might not be as clear (since they cannot use the highest LTE signals) and you can make calls and data at the same time. But it does not solve the issue.

    (2) there are rumors (but you didn't hear that from me that we only are not supposed to discuss beta software program Apple in this forum) that the new version of Apple Beta for iOS (which also includes an update of the software carrier Verizon to 26.0) seems to solve this problem. So, there's a light at the end of the tunnel.

  • Problem with some fonts of symbols after the installation of the Sierra

    Hello

    I have recently upgraded the OS on my iMac late 2012 for Sierra, since doing so, I noticed a problem with several fonts.

    All symbolic symbols Apple to Wingdings fonts not correctly displayed in the font book. Apple symbols looks like a standard wheelbase of san, and other symbolic fonts just show as question marks '?' where the images should be.

    In text editing, that I can't even see the symbolic fonts like Zapf Dingbats and Wingdings in the selector. However, they all work well in Adobe Illustrator (CS5) and Microsoft Word 2011. Apple symbols still looks like a standard font.

    I already tried the following:

    1. check the fonts in font book

    2 fix the duplicates in the font book

    3. using the "Restore Standard fonts" option in the font book

    4 deleting a file in the folder Preferences plist Fonts

    5 deleted the cache of police and the database

    I'm out of ideas. Has anyone else had the same problem found a fix?

    Kind regards

    Greville

    I'm just to add that I used the recovery partition to do a clean install of Sierra on a hard drive external and then booted into it to see if it had the same problem.

    And he does. Wingdings and other photo fonts appear as '?' in boxes where the letters must be in the font book.

    So this seems like a problem with the way Sierra displays these fonts, not with the font files themselves.

Maybe you are looking for

  • Upgrade to iOS 10. Cannot connect on app store

    I have upgraded to iOS 10. Now I can't connect to the app store. The "updates" show that I have updates pending. When I switch to "updates" it shows the list for 2 seconds the list disappear. I Iphone6 more. Help please.

  • Firefox 34.0.5 on Yosemite 10.10.1 refuses to work on YouTube

    I have Firefox 34.0.5 and installed and uninstall Flash Player several times. When I go on YouTube, I don't see is a black window. He has no control whatsoever. I disabled noscript and adblocking and no difference. I can't yet the animation to play p

  • Lenovo shot vibe root

    This is how the root of the forum lenovo China. http://Club.Lenovo.com.CN/thread-896427-1-1.html but all the files are in cloud storage China requiring China to enter phone number. can someone download and download again in the box / box / mega / med

  • iCloud never be online on my computer

    I have a MacBook Air.  Whenever I turn it on, it tells me that I have to login to iCloud.  So, I login to iCloud with my apple ID, and I leave it connected.  The next time I turn on my computer, I have to do the same.  My ID apple remains ever connec

  • Problem Keithley 236 control using a GPIB/USB cable

    Hello, I would like to use my PC to control Keithley 236 SMU to make some simple steps I - V (sweeping voltage and measuring the current). If you can give me some advice about my problems, I will be very grateful. Situation: I have a PC (windows XP)