mysql 根據B表字段 修改 A表中的值

update table1 a1 inner join (select a.id from table1 a
                   inner join table2 b
                   on b.id=a.id
where b.name='nameValue')tmp on a1.id=tmp.id
set a1.item='value'

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章