Be aware of computed columns that use complex formula or call functions, they may lead to performance problems:
create function getsum(@id int)
returns int
as
begin
return (select sum(id) from sysobjects where id < @id)
end
GO
create table a(id int identity(1,1) primary key,a int,sum_id as dbo.getsum(id))
insert a select id from sysobjects
select * from a -- the function getsum is called for each row to compute sum_id
In this case, I prefer to use a trigger to compute the column.