How To Run the Anonymous Block Again

Q

How To Run the Anonymous Block Again? - Oracle DBA FAQ - Introduction to PL/SQL

✍: FYIcenter.com

A

If you have an anonymous block defined in your session, you can run it any time by using the "/" command as shown in the following script:

SQL> set serveroutput on;

SQL> begin 
  2    dbms_output.put_line('This is a PL/SQL FAQ.'); 
  3  end;
  4  /
This is a PL/SQL FAQ.

PL/SQL procedure successfully completed.

SQL> /
This is a PL/SQL FAQ.

PL/SQL procedure successfully completed.

2007-04-25, 4875👍, 0💬