UPDATE犯迷

select  * from  T_CONVERT where  businessid='423'   and  convert_time>20101001000000 and  convert_time<20101007240000  
select * from T_CONVERT where businessid='423'  and convert_time>20101001000000 and convert_time<20101007240000

 

查询出结果后要对一些特定的列进行修改,当时犯迷的地方是:认为不能根据将要修改的字段更新此字段

 

update t_convert set subbusiness_id =505 where subbusiness_id =506  and convert_time>'20101001000000' and convert_time<'20101007245959'

发布了15 篇原创文章 · 获赞 1 · 访问量 2万+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章