I found a script from google but it's giving error SQL> create or replace procedure purge_audit_trail ('90') as 2 purge_date date; 3 begin 4 purge_date := trunc(sysdate-days); 5 dbms_system.ksdwrt(2,'AUDIT: Purging Audit Trail until ' || 6 purge_date || ' started'); 7 delete from aud$ where ntimestamp# < purge_date; 8 commit; 9 dbms_system.ksdwrt(2,'AUDIT: Purging Audit Trail until ' || 10 purge_date || ' has completed'); 11 end; 12 / Warning: Procedure created with compilation errors. SQL> show errors Errors for PROCEDURE PURGE_AUDIT_TRAIL: LINE/COL ERROR -------- ----------------------------------------------------------------- 1/30 PLS-00103: Encountered the symbol "90" when expecting one of the following: <an identifier> <a double-quoted delimited-identifier> current delete exists prior please let me know what could be the problem On Fri, Mar 30, 2012 at 2:15 AM, Nagaraj S <nagaraj.chk@xxxxxxxxx> wrote: > Kindly give me steps that need to schedule Audit Purge Job for purging the > table SYS.AUD$ records more than 90 days -- //www.freelists.org/webpage/oracle-l