悬赏园豆:20
[已关闭问题]
CREATE PROCEDURE Getdefaultinfo<br><br> AS <br><br>/*顶部交换技能*/<br>select top 30 FTID,FuserID,dbo.TurnUserName(FuserID) as userName,FShi,FQu,substring(FTtitle,40,50) as title,FTechKey,FPClassID,dbo.TurnClassName(FPClassID) as PClassName,FBClassID,dbo.TurnClassName(FBClassID) as BClassName,dbo.FormatFtime(FcreateTime) as createTime from T_Techtory where FTtype=1 and FmoneyArea in (1,3) order by FcreateTime desc <br><br>/*顶部交易技能*/<br>select top 30 d.FUserLoginName,a.FTID,substring(a.FTtitle,40,50) title,a.FPClassID,a.FBClassID,b.FclassName fpc,a.FuserID,c.FclassName fbc,FShi,FQu,dbo.FormatFtime(a.FcreateTime) createTime from T_Techtory a left join T_ClassType b on a.FPClassID=b.FClassID left join T_ClassType c on a.FBClassID=c.FClassID left join T_UserInfo d on a.FuserID=d.FuserID where a.FTtype=1 and a.FmoneyArea in(2,3) order by a.FcreateTime desc <br><br>/*最新需求*/<br>select top 24 ftid, fttitle,Fmoney from t_techtory where FTtype='2' and Fispublic='0'and FStatus='0' and fdatetime >getdate() order by fcreatetime desc<br><br>/*热门需求*/<br>select top 24 ftid, fttitle,Fmoney from t_techtory where FTtype='2' and Fispublic='0'and FStatus='0' and fdatetime >getdate() order by FTechCredit desc<br><br>/*推荐交换*/<br>select top 16 ftid, fttitle,FtechKey,FuserID,dbo.TurnUserName(FuserID) as userName from t_techtory where FTtype=1 and Frecommend>0 and FmoneyArea in(1,3) and fdatetime >getdate() and Fispublic='0'and FStatus='0' and FmoneyArea in(1,3) order by fcreatetime desc<br><br>/*推荐交易*/<br>select top 24 ftid,fttitle,fuserid from t_techtory where fttype=1 and Frecommend>0 and FmoneyArea in(2,3) and fdatetime >getdate() order by fcreatetime desc<br><br>/*热门交换*/<br>select top 16 ftid, fttitle,FtechKey,FuserID,dbo.TurnUserName(FuserID) as userName from t_techtory where FTtype=1 and fdatetime >getdate() and Fispublic='0'and FStatus='0' and FmoneyArea in(1,3) order by fskillhit desc<br><br>/*读取社区图片*/<br>select top 2 title,imgurl,link from usernews order by [time] desc<br><br>/*资讯频道图片*/<br>select top 2 FnewsID, Ftitle,FhtmlUrl from T_News where FType='N00002' and FisTopNews=1 order by fregtime desc<br><br>/*资讯频道内容*/<br>select top 12 FnewsID, Ftitle from T_News where FType='N00002' and FisTopNews<>1 order by fregtime desc<br><br>/*综合频道图片*/<br>select top 2 FnewsID, Ftitle,FhtmlUrl from T_News where FType='N00003' and FisTopNews=1 order by fregtime desc<br><br>/*综合频道内容*/<br>select top 12 FnewsID, Ftitle from T_News where FType='N00003' and FisTopNews<>1 order by fregtime desc<br><br>/*申请友情链接*/<br>select * from t_link order by displayorder<br>GO
问题补充:
对了,怎么缓存法?最好有个实例代码...