• trying to save this as a stored procedure in SQL2005, but am getting an error: Cannot assign a default value to a local variable.

    Any help is greatly appreciated, thanks!