SP中的日期比较 [英] Date Comparing in SP
本文介绍了SP中的日期比较的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在使用以下内容:
I''m using the Following:
ALTER procedure [dbo].[searchEstimate1] (@p_serchStr nvarchar(30), @v_done smallint OUTPUT)
as
DECLARE @SerchValueIDTBL TABLE (SerchValueID bigint)
BEGIN
SET @p_serchStr = UPPER('%'+@p_serchStr+'%')
delete from @SerchValueIDTBL
SET @v_done = 1
insert into @SerchValueIDTBL
select EstimateID
from EstimateMaster
where UPPER(convert(varchar(50),EstimateDate))like @p_serchStr
SELECT *
FROM EstimateSummary
where EstimateID IN ( select distinct SerchValueID
from @SerchValueIDTBL)
SELECT @v_done
END
在这个过程中,当我通过日期是2010年6月2日的日期时,
并且当May两个空格22 2010时,它不会显示
in this when i Pass the date that is jun two space 2 2010 then its takes
and when May two space 22 2010 then it does not display
推荐答案
检查本文:
http://demiliani.com/blog/archive/2006/01/19/3384.aspx [ ^ ]
Check this article:
http://demiliani.com/blog/archive/2006/01/19/3384.aspx[^]
这篇关于SP中的日期比较的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文