obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

obclient> SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
call dbms_xplan.enable_opt_trace();
call dbms_xplan.set_opt_trace_parameter(identifier=>'obdiag_eNfKrw', `level`=>3);
explain SELECT /*ligang1710*/
        a.order_id,
        a.use_type,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        (h.sensi_flag is null OR h.sensi_flag in (1,1000))) unfinished_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (2,96,97) ) sensi_count,
        ( SELECT COUNT( 1 ) FROM t_order_file g,t_file h WHERE g.order_id = a.order_id AND h.file_id = g.file_id AND
        h.sensi_flag in (98,99)) black_count,
        u.censor_flag,u.sensi_handle_flag
        FROM
        t_order a
        LEFT JOIN t_set s ON a.set_id = s.set_id
        LEFT JOIN t_set_security_policy t on s.set_id = t.set_id
        LEFT JOIN t_security_policy u on t.policy_id = u.policy_id
        WHERE
        a.state_date > DATE_ADD(now(),INTERVAL - 3 HOUR) and a.r_tenant_id = 'woqu'
        AND a.state_date  <  DATE_ADD(now(),INTERVAL - 60 SECOND)
        AND a.state = '00'
        AND a.checked_flag is null
call dbms_xplan.disable_opt_trace();

