Viewing 15 posts - 166 through 180 (of 244 total)
Bet you a quid that it is...
reet -But how you going to get rid of that Left join?
It would certainly not be advisable...
July 11, 2006 at 7:14 am
Both can be transalated fairly strighforwardly into 'where not(ClaimStatusID = 2 and DateClosed is null)'
--------------------------------------------------------------------------------------------------
select
July 11, 2006 at 6:18 am
select
'not(P and Q)' filter, * from @t where not(
July 11, 2006 at 5:55 am
As well as following Johns advice you sould create an indexed view. See code below i have guessed some details about you data inparticulare the the columns to place the...
July 11, 2006 at 5:42 am
ah yes didnt bother to test it. Nice use of data diff..
July 3, 2006 at 2:42 am
small adjustment to get rid of time portion..
CREATE FUNCTION dbo.AddDays(@MyDate DATETIME, @Days INT)
RETURNS DATETIME
AS
BEGIN
RETURN cast(floor(cast(DATEADD(dd,@Days,DATEDIFF(dd,0,@MyDate))as float))as smalldatetime)
END
July 2, 2006 at 2:33 pm
yep it works a treat. Just deleted 25 lines of dynamic sql and replaced it with your 5 lines
thanks
June 30, 2006 at 7:50 am
I cant imagine that performance will ever be an issue with this kind of sp. Infact you shouldnt really build queries like this into prodution code at all. Anyway here...
June 24, 2006 at 8:07 am
See Stored Proc below
--------------------------------------------------
CREATE
TABLE t1 (a int, b int, c...
June 24, 2006 at 7:58 am
Viewing 15 posts - 166 through 180 (of 244 total)