例如…
ALTER PROCEDURE [dbo].[Reports_Dashboard_Get_Sav] -- Add the parameters for the stored procedure here @startDate datetime,@endDate datetime,@companyID int=null set @days=datediff(m,@startdate,@enddate) if (@days)=0 set @days=1
这不是我的代码,但如果这是区分大小写,那么@days将无法正确计算,因为startDate / startdate和endDate / enddate变量不匹配…