ITeye博客

批量生成sql,并执行

fourfire · 2006-12-18 10:50 · Markdown

sql 代码

 

  1. set heading off ;
  2. set feedback off  ;
  3. SPOOL ON.SQL;
  4. select 'alter table '||a.Table_Name||' move tablespace FSPTDATA;'
  5. from sys.all_tables a
  6. where a.owner = 'FSPT'
  7. and a.tablespace_name <> 'FSPTDATA';
  8. SPOOL OFF;
  9. @ON.SQL;

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。