delete from user where uid in(
select uid from (
select uid as xiaojian from user
where (uid between 81 and 96)
having xiaojian<91 )
as temp );
uj5u.com熱心網友回復:
重復的問題,這個子查詢單獨不能執行,問題就在這里,自己想想原因(這是你自己挖的坑)select uid from (
select uid as xiaojian from user
where (uid between 81 and 96)
having xiaojian<91 )
as temp
uj5u.com熱心網友回復:
把select結果集create到臨時表 然后再執行deletecreate table tmp select xxx
delete from tb where xxx in (select * from tmp)
轉載請註明出處,本文鏈接:https://www.uj5u.com/shujuku/103727.html
標籤:MySQL
上一篇:安裝MySql時彈出 無法定位程式輸入點fasetround于元件 MSVCR120.dll上 提示框
下一篇:用sqoop連接db2
