set serveroutput on size 1000000 BEGIN for r_tab_part in (select table_name from user_tables where partitioned = 'YES') loop begin MNP.CREA_PARTIZIONE('01/10/'||to_char(sysdate,'yyyy'),r_tab_part.table_name, '&1'); MNP.CREA_PARTIZIONE('01/04/'||to_char(sysdate+366,'yyyy'),r_tab_part.table_name, '&1'); exception when others then dbms_output.put_line('errore di creazione delle partizioni per la tabella '||r_tab_part.table_name||SQLERRM); end; end loop; END; /