阅读背景:

具有datediff函数的慢速T-SQL查询

来源:互联网 

I have a query which runs fast when the date clause "and datediff(day,con2.DT_DateIncluded),'2017-01-01')<=0" in the code below isn't used in the query, but runs slowly when it is included. Though it runs fast when I run just the part "select top 2 ID_Contact...", even including the date clause. I have this query on a classic ASP application, and it can't be converted in to a stored procedure (project scope reasons). Can you help me find a way to improve the performance of the full query just by changing the query code?I have a query which runs fast when the date cl




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: