Have a look at your code:
declare @sal1 as int,@sal2 as int
set @sal1=1000
set @sal2=2500
select trdt as trdt from #tes where cccd='hit07' and CAST(trdt as datetime)
between @stdt and @eddt
and for my, now:
DECLARE @stdt DATETIME
DECLARE eddt DATETIME
SET @stdt='2007-01-08'
SET @eddt='2007-03-31'
SELECT trdt
FROM #tes
WHERE cccd='hit07' and trdt BETWEEN @stdt and @eddt
Do you see the difference?