title: error while truncating tables from oracle db
body: <p>I am doing something like this in a procedure to clear all data from all tables in my database.</p>
  
  <pre><code>LOOP
      dbms_utility.exec_ddl_statement('alter table ' || c.owner || '.' || c.table_name || ' disable constraint ' || c.constraint_name);
    END LOOP;
   .
   .
   .
  
  LOOP
      EXECUTE IMMEDIATE 'TRUNCATE TABLE ' || t.table_name ;
    END LOOP;
  </code></pre>
  
  <p>Now , this throws the following error :</p>
  
  <pre><code>ORA-03291: Invalid truncate option - missing STORAGE keyword
  ORA-06512: at "MYSCHEMA.CLEAR_DATA", line 15
  ORA-06512: at line 2
  Process exited.
  Disconnecting from the database MYDB.
  </code></pre>
  
  <ol>
  <li>Why is a storage keyword mandatory? I thought <code>DROP STORAGE</code> was the default.</li>
  <li><p>Even specifying storage close, as in,</p>
  
  <p>EXECUTE IMMEDIATE 'TRUNCATE TABLE ' || t.table_name || 'DROP STORAGE';</p>
  
  <p>doesn't help. The error is the same.</p></li>
  <li>I thought it might have something to do with foreign constraints on some tables. Hence, the 'disable constraint' earlier in the script  </li>
  </ol>