Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Performance issue in a function
Sujatha wrote:
>Can you suggests something?
Switching between SQL and PL/SQL generally is bad idea at least from performance viewpoint. The best thing is to incorporate the logic into the very sql statement. On the other hand just because your query returns 1 row that really doesn't mean that function is called once, it can be called zillion times and only later some other filters applied. So check how many times your function is applied. Trace could be a tool here. If you cannot incorporate function logic into the sql statement then generally you'd like to apply function as late as possible after all other filters are applied.
Gints Plivna
http://www.gplivna.eu/
Received on Wed Jul 12 2006 - 15:11:10 CDT