I think Waleed's point is that he is yet to see an
example where such an optimization has taken place.
cheers
connor
--- Kevin Toepke <[EMAIL PROTECTED]> wrote: >
One of the optimizations behind the DETERMINISTIC
> keyword is that Oracle
> caches previously computed values. If you pass the
> sam
One of the optimizations behind the DETERMINISTIC keyword is that Oracle
caches previously computed values. If you pass the same values into the
function twice, the function body will execute at least once and at most
twice. You can NOT count on the function body being executed for each call.
This
As far as I know, with all current releases of Oracle,
determinism is purely for function based indexes. The
deterministic keyword indicates that the function
values when you created the index are still preserved
when you query it.
Thus the "first" execution was during index creation,
and the "se
drop table test_det;
create table test_det (c1 date);
create or replace function f2 (p1 in number, p2 in number) return number
deterministic is
pragma autonomous_transaction;
begin
insert into test_det values (sysdate);
commit;
return(p1 * p2);
end;
/
select f2 (1,3) from dual where f2 (1,3)