Hello,
I have a big view which has very complicated busness logic.
The cost of the execution plan(explain plan for) is very high.
If I rewrite this view to a stored procedure that calculates for each field and store the value to an interim table, I believe it will improve the performance dramatically.
My question is:
How do I compare the performance result?
Here is what I want:
Original:
explain plan for
select * from vw_big where id =11;
select plan_table_output from table(dbms_xplan.display());
after I change:
explain plan for
execute sp_get_vw_data(11); --this sp will insert to table tbl_1
select * from tbl_1
select plan_table_output from table(dbms_xplan.display());
I know this does not work because explain plan just work for query.
How can I get the cost from my new method?
Thank you very much
I have a big view which has very complicated busness logic.
The cost of the execution plan(explain plan for) is very high.
If I rewrite this view to a stored procedure that calculates for each field and store the value to an interim table, I believe it will improve the performance dramatically.
My question is:
How do I compare the performance result?
Here is what I want:
Original:
explain plan for
select * from vw_big where id =11;
select plan_table_output from table(dbms_xplan.display());
after I change:
explain plan for
execute sp_get_vw_data(11); --this sp will insert to table tbl_1
select * from tbl_1
select plan_table_output from table(dbms_xplan.display());
I know this does not work because explain plan just work for query.
How can I get the cost from my new method?
Thank you very much