公司的时间戳存证业务,对发版过程中间数据处理需要用到存储过程.对此做一个简短记录,以免遗忘. DROP procedure record_timestamp_deal ; ##创建存储过程 create procedure record_timestamp_deal() begin ); ; # declare existence boolean ; ##从时间戳记录表中获取ID存入游标 declare cur cursor for select id from time_stamp_log;…
1.Mysql update语句赋值嵌套select 点击(此处)折叠或打开 update a set col=(select col from a where id='5') where id>5 and id<10; 报错了 ERROR 1093 (HY000): You can't specify target table 'a' for update in FROM clause 经过研究 发现是 mysql 定义update语句不能同时对同一张进行set 赋值操作,也就是说 upd…