Windows2k3下写一个db2脚本

[复制链接]
查看11 | 回复2 | 2012-5-7 15:28:04 | 显示全部楼层 |阅读模式
delete from [table] whereselect * from name where csny>date_sub(date(now()),interval 1 month);+----+--------+------+------------+| id | xm
| xb | csny
|+----+--------+------+------------+| 16 | Apri26 | gl | 2012-04-26 | +----+--------+-----...
回复

使用道具 举报

千问 | 2012-5-7 15:28:04 | 显示全部楼层
到syscat.tables里面去查找一年前的自建表, 查到了表名字之后删除就是了。db2 => select tabschema, tabname, create_time from syscat.tables where create_time < current timestamp - 1 year...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行