日期:2014-05-18  浏览次数:20536 次

下列语句怎么修改啊?
sg_clnt_clientshare记录了客户共享的信息
现要删除共享人等于客户所有人的记录

delete from sg_clnt_clientshare a where a.shareuserid = (select b.operator from sg_clnt_client b where b.customerid = a.clientid)

------解决方案--------------------
delete a 
from 
sg_clnt_clientshare a,sg_clnt_client b 
where 
b.customerid = a.clientid and a.shareuserid = b.operator