账号通
    

账号  

密码  

2963

查看

14

回复
主题:[求助]SQL语句的问题求助官方 [收藏主题] 转到:  
ini111 当前离线

266

主题

0

广播

0

粉丝
添加关注
级别:二年级

用户积分:1325 分
登录次数:217 次
注册时间:2008/12/2
最后登录:2020/2/7
ini111 发表于:2012/3/9 11:29:26   | 显示全部帖子 查看该作者主题 楼主 
科汛智能建站系统

数据库一直占CPU100%,换成SQL的也不行。

检测到以下SQL有问题,但我找自定义SQL没有找到,请帮助。



1、

Select ID,Title,Tid,ReadPoint,InfoPurview,Fname,Changes,AddDate,Popular,ChannelID,hits,username From (select ID,Title,Tid,ReadPoint,InfoPurview,Fname,Changes,AddDate,Popular,1 as ChannelID,hits,Inputer As username From KS_Article Where DelTF=0 And Verific=1 And keywords like ''%儿科学%'' Union All select ID,Title,Tid,ReadPoint,InfoPurview,Fname,0 as Changes,AddDate,Popular,3 as ChannelID,Hits,Inputer As username From KS_DownLoad Where DelTF=0 And Verific=1 And keywords like ''%儿科学%'' Union All select ID,Title,Tid,0 as ReadPoint,0 as InfoPurview,Fname,0 as Changes,AddDate,Popular,5 as ChannelID,Hits,Inputer As username From KS_Product Where DelTF=0 And Verific=1 And keywords like ''%儿科学%'' Union All select ID,Title,Tid,ReadPoint,InfoPurview,Fname,Changes,AddDate,Popular,111 as ChannelID,hits,Inputer As username From KS_U_esf Where DelTF=0 And Verific=1 And keywords like ''%儿科学%'') a  ORDER BY ADDDATE DESC,ID Asc



2、

Select  ID,Tid,Title,ChannelID,InfoID,Intro,AddDate,Fname From KS_ItemInfo Where Verific=1 and deltf=0 And (Title like ''%瀛ょ%'' or Title like ''%ょ嫭%'' or Title like ''%嫭鐥%'' or Title like ''%鐥囧%'' or Title like ''%囧効%'' or Title like ''%効绔%'' or Title like ''%绔ヨ%'' or Title like ''%ヨ%'' or Title like ''%涓%'' or Title like ''%涓鸿%'' or Title like ''%鸿瘎%'' or Title like ''%瘎瀹%'' or Title like ''%瀹氶%'' or Title like ''%氶噺%'' or Title like ''%噺琛%'' or Title like ''%琛s%'' or Title like ''%st%'' or Title like ''%ty%'' or Title like ''%yp%'' or Title like ''%pe%'' or Title like ''%e=%'' or Title like ''%=0%'') Order by ID Desc

3、

SELECT TOP 1 I.ChannelID,I.InfoID as ID,I.Title,I.Tid,I.Intro,I.PhotoUrl,I.AddDate,I.Inputer,I.Popular,I.Fname,I.Hits FROM [KS_ItemInfo] I  Inner Join KS_Channel C On I.ChannelID=C.ChannelID Where C.ChannelStatus=1 And I.Verific=1 And I.DelTF=0 And I.Tid In (Select ID From KS_Class Where DelTF=0 AND TS LIKE '%20109354559082%') And I.Recommend=1 And I.Slide=1 And I.PhotoUrl<>'' ORDER BY I.IsTop Desc,id desc

4、

Select  ID,Tid,Title,Intro,AddDate,Fname From KS_Article Where Verific=1 and deltf=0 And (Title like ''%北京%'' or Title like ''%京四%'' or Title like ''%四月%'' or Title like ''%月一%'' or Title like ''%一日%'' or Title like ''%日孤%'' or Title like ''%孤独%'' or Title like ''%独症%'' or Title like ''%症家%'' or Title like ''%家长%'' or Title like ''%长培%'' or Title like ''%培训%'') Order by ID Desc

5、

select Count(1) from KS_ItemInfo  Where Verific=1 and deltf=0 And (Title like '%瀛ょ%' or Title like '%ょ嫭%' or Title like '%嫭鐥%' or Title like '%鐥囧%' or Title like '%囧効%' or Title like '%効绔%' or Title like '%绔ヨ%' or Title like '%ヨ%' or Title like '%涓%' or Title like '%涓鸿%' or Title like '%鸿瘎%' or Title like '%瘎瀹%' or Title like '%瀹氶%' or Title like '%氶噺%' or Title like '%噺琛%' or Title like '%琛s%' or Title like '%st%' or Title like '%ty%' or Title like '%yp%' or Title like '%pe%' or Title like '%e=%' or Title like '%=0%')







我自定义的SQL中没有语句,是系统中的吗?请帮助。

 
  支持(0) | 反对(0) 回到顶部顶端 回到底部底部
ini111 当前离线

266

主题

0

广播

0

粉丝
添加关注
级别:二年级

用户积分:1325 分
登录次数:217 次
注册时间:2008/12/2
最后登录:2020/2/7
ini111 发表于:2012/3/9 14:07:08   | 显示全部帖子 查看该作者主题 沙发 

已查出。是搜索页面和tags页面的SQL。

我把这两个文件改名,CPU马上就下来了!官方能帮助解决一下吗?


 
  支持(0) | 反对(0) 回到顶部顶端 回到底部底部
<上一主题 | 下一主题 >
Powered By KesionCMS Version X1
厦门科汛软件有限公司 © 2006-2016 页面执行0.10938秒 powered by KesionCMS 9.0