Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
What Happens If Recursive Calls Get Out of Control
What Happens If Recursive Calls Get Out of Control? - Oracle DBA FAQ - Creating Your Own PL/SQL Procedures and Functions
✍: FYIcenter.com
What happens if your code has bug on recursive procedure calls, which causes an infinite number nested procedure calls? The answer is so good. Oracle server seems to offer no protection calling stack limit. The script below shows you a badly coded recursive procedure. If you run it on an Oracle 10g XE server on Windows, your server will out of control and keep using virtual memory to satisfy the growing calling stack. You have to reboot your server to control back.
SQL> CREATE OR REPLACE PROCEDURE STACK_TEST AS 2 --Warning: do not run this procedure on your server 3 PROCEDURE STACK AS 4 BEGIN 5 STACK; 6 END; 7 BEGIN 8 STACK; 9 END; 10 / SQL> EXECUTE STACK_TEST; (your server keep running with 100% CPU and memory usage)
2007-04-25, 5289👍, 0💬
Popular Posts:
How To Use Subqueries in the FROM clause? - MySQL FAQs - SQL SELECT Statements with JOIN and Subquer...
What exactly happens when ASPX page is requested from Browser? Note: - Here the interviewer is expec...
Write down the equivalent pointer expression for referring the same element a[i][j][k][l]? a[i] == *...
Are risk constant through out the project ? * Never say that risk is high through out the project. R...
How To Get the Minimum or Maximum Value of an Array? - PHP Script Tips - PHP Built-in Functions for ...