医药CRM系统开发

自已做医药CRM系统有四年了,终于可以算个产品了,努力市场化,今年重种将医药营销的理念加入CRM

导航

select proxyid,hisid,proxyid+hisid as zhcx into #sale_proxy  from zy_yp1_proxysalesdetail group by proxyid,hisid
insert into zy_yp1_proxy_his(proxyid,hisid) select proxyid,hisid from #sale_proxy where proxyid+hisid not  in(select  proxyid+hisid from zy_yp1_proxy_his)
select * from zy_yp1_proxy_his where hisname is null
update zy_yp1_proxy_his set hisname=left(b.hisname,30) from zy_yp1_proxy_his a,zy_yp1_his b where a.hisid=b.hisid
drop table #sale_proxy