update app_biz_acw acw set (buscode,bustype)=(
select min(his1.buscode),min(his1.bustype) from app_biz_custhisrec his1 where
(select count(*) from app_biz_custhisrec his2
where his2.connecttime>=(his1.connecttime-3/24/60)
and his2.connecttime
and his2.agcid=his1.agcid
and his2.telno=his2.telno
group by his2.customerid,his2.agcid
)=0
and acw.agcid=his1.agcid
and acw.telno=his1.telno
and his1.connecttime
and his1.connecttime>(acw.connecttime-5/24/60)
),acw.inputtype='2'
where acw.buscode is null
这个 buscode,bustype 更新不了. 哪位有空帮我看下
这个sql意思是 不知道怎么描述。能看懂的帮我看下吧
[b]问题补充:[/b]
不报错误.
inputtype可以update成功。
buscode,bustype不能
[b]问题补充:[/b]
这个sql效率太低了..
改了下..2个表加起来就2W的数据
2分钟还没执行完..
有什么办法提高效率呢..