Re: ALTER SESSION SET QUERY_REWRITE_INTEGRITY = TRUSTED
From: ddf <oratune_at_msn.com>
Date: Tue, 28 Jul 2015 08:22:01 -0700 (PDT)
Message-ID: <6028e969-4d17-467a-919f-5c793a431816_at_googlegroups.com>
On Monday, July 27, 2015 at 5:42:22 PM UTC-6, Sanae wrote:
> ddf thank you for your reply but I did not really understand, I am debutante in database I need to execute this request on my trigger
> os what can do to make it happen?
> regrads
> thank you in advance
2 execute immediate 'ALTER SESSION SET QUERY_REWRITE_INTEGRITY = TRUSTED'; 3 end;
4 /
Date: Tue, 28 Jul 2015 08:22:01 -0700 (PDT)
Message-ID: <6028e969-4d17-467a-919f-5c793a431816_at_googlegroups.com>
On Monday, July 27, 2015 at 5:42:22 PM UTC-6, Sanae wrote:
> ddf thank you for your reply but I did not really understand, I am debutante in database I need to execute this request on my trigger
> os what can do to make it happen?
> regrads
> thank you in advance
I have to correct my response as in 11.2.0.3 I can get that statement to work using execute immediate:
SQL> show parameter query_rewrite_integrity
NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ query_rewrite_integrity string enforcedSQL> begin
2 execute immediate 'ALTER SESSION SET QUERY_REWRITE_INTEGRITY = TRUSTED'; 3 end;
4 /
PL/SQL procedure successfully completed.
SQL> show parameter query_rewrite_integrity
NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ query_rewrite_integrity string TRUSTEDSQL> You might want to consider moving the execute immediate setting the query_rewrite_integrity to before any other execute immediate statements and before the call to dbms_advanced_rewrite.
David Fitzjarrell Received on Tue Jul 28 2015 - 17:22:01 CEST