摘要:全文阅读见PL/SQL FAQHow can one see if somebody modified any code?The source code for stored procedures, functions and packages are stored in the Oracle Data Dictionary. One can detect code changes by looking at the TIMESTAMP and LAST_DDL_TIME column in the USER_OBJECTS dictionary view. Example:SELECT OB
阅读全文
摘要:Cursor LoopExplicitly declared cursor and recordCREATE ORREPLACE PROCEDURE <procedure_name> ISCURSOR <cursor_name> IS<SQL statement><record_name> <cursor_name>%ROWTYPE;BEGIN OPEN <cursor_name> LOOP FETCH <cursor_name> INTO <record_name>; EXIT WHEN <
阅读全文
摘要:Oracle提供三种样式的Loop结构1. The Basic LoopThe BASIC loop repeats until a condition is met. Because the condition is tested at the end of the loop, the BASIC loop will always execute at least once.A simple loop runs until you explicitly end the loop. The syntax for a simple loop is as follows:LOOP [Sequ...
阅读全文