首頁  >  文章  >  後端開發  >  php delete select 的有关问题

php delete select 的有关问题

WBOY
WBOY原創
2016-06-13 13:04:21845瀏覽

php delete select 的问题

delete from sinykk_love_web where id in (select id from sinykk_love_web group by site_url having count(site_url)>1)


1093 - You can't specify target table 'sinykk_love_web' for update in FROM clause


改成如下就好


delete from sinykk_love_web where id in (select temp.id from (select m. id,m.site_url from sinykk_love_web m)? temp group by temp.site_url having count(temp.site_url)>1)

陳述:
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn