我有以下语句作为我的存储过程的一部分,我收到一个错误,说明非布尔类型的表达式指定的情况sql错误 sql语句是: -
AND ( CASE
WHEN (CONVERT(DATE, Cm_Opt_Tsk_Task_S.Tsk_DUEDATE) <= @EndDate )
AND (ISNULL(Cm_Cfg_Tst_TaskStatus_S.Tst_DESCRIPTION, '') IN ('Completed',
'Cancelled',
'Closed',
'Renamed',
'Open',
'Started',
'Pending')) THEN
(SELECT COUNT(*)
FROM Cm_Opt_Tsk_Task_S AS TotalInStandard)
END )
我尝试分解声明,但我仍然收到错误