I have a long running sql which uses a view and was taking more than 20 minutes to get the result.
I can able to fix this sql using a Parallel hint.(It is now giving the result in seconds). The issue is we can not change the code in the background.
How can I create a sql profile so that we need not to change the code?
The below sql is modified sql (Working) :-
select /*+ PARALLEL*/ * from ps_wklst_vw where order_num<250;
The Original sql was as follows:-
select * from ps_wklst_vw where order_num<250;