Ollie :
Whenever you switch between languages you will incur an overhead, called a context switch.\n\n( http://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:60122715103602 )\n\nThere is even an overhead in moving between SQL and PL/SQL and they are very tightly integrated. Moving between Java and PL/SQL will therefore always be less efficient than pure PL/SQL.\n\nJava Stored Procedure Vs PL/SQL Stored Procedure\n\nAs for the performance once the context switching has taken place, your benchmarking will give you the best answer but FWIW, as PL/SQL is so tightly integrated within the Oracle database it should perform better than the stored Java code if you are fetching data or interacting with the DB, if you are purely manipulating already fetched data, it would depend upon what you are then doing to the data and your benchmark will tell you the answer.",
2012-01-19T12:01:48