开发者

Can I have an editable computed-column?

Is it possible to edit computed-column values?

I have a computed-col in my table, 开发者_运维百科sometimes, I need to enter an individual value that is not the computed value.

Is there a way to store it in the computed col, or I have to make an additional col?


No, computed columns are by design always readonly.

You need to change the underlying actual columns (that the computed column relies on) to change the computed column.

This is still the same in SQL Server 2008.

What you could do is have a regular column, and a trigger that would sometimes update that column, and sometimes skip the update.

Marc

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜