>Hi everybody,
>
>If there a way to check for two date variables to be exactly one year apart or not?
>
>Thanks in advance.
DECLARE @Test1 datetime
DECLARE @Test2 datetime
SET @Test1 = '20080101'
SET @Test2 = '20090101'
SELECT CASE WHEN DATEADD(mm,12,@Test1) = @Test2
THEN 'Hurray'
ELSE ':-(((((' END AS TestMe
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.