lunedì 29 agosto 2011

OCPJP SCJP CX-310-065 Certification Exams examples sources.


In attatchment zip with some source example for OCP JP SCJP.

Zipped as ecplise project.

lunedì 22 agosto 2011

Clear content of users tables reviewd with exception handling

begin for t in (select table_name from user_tables) loop BEGIN execute immediate 'TRUNCATE table '||TRIM(t.table_name); EXCEPTION WHEN OTHERS THEN DBMS_OUTPUT.put_line (' ERROR '); END; end loop; end;

venerdì 19 agosto 2011

Oracle total size of tables


Using the fooling SQL command in SQL Plus or TOAD:

SELECT SUM(BYTES) FROM USER_SEGMENTS WHERE SEGMENT_TYPE='TABLE';

this is the result