what I typically do is test for the 0 in a case statement:
declare @a int
,@b int
select @a = 2
,@b = null
select case
when @a+@b is null = 0 then 0
else 10 / (@a + @b)
end as [noDevideByZeroError]
btw, you should use the t-sql forum or some other forum. Script Library is just for posting cool/helpfull code.
thanks
Be One with the Optimizer
TG