现在有一个任务,有一批的命令,都是update ,insert,delete 的批操作。 还有一个要求,在执行操作时需要记录下更新数据的历史状态。 例如: update tab1 set col='**',col2='***' where id in (select tid from tab2 where enable='Y') 我的处理是这样的: 1.首先解析后得到: select * from tab1 where id in (select tid from tab2 where enab