这个问题已经在这里有了答案:




已关闭8年。






我只想知道如何在SQL Server中的现有表列中添加注释?看起来很简单,但我发现在5个第一结果中什么都没有发现,这使我的搜索引擎大跌眼镜。

编辑

与其使用UI,不如知道SQL查询。

最佳答案

在SQL Server Management Studio中创建新表时,请引用下面提到的屏幕快照,以将说明添加到列中。

另一种编程方式

EXEC sp_updateextendedproperty
@name = N'MS_Description', @value = 'Your description',
@level0type = N'Schema', @level0name = dbo,
@level1type = N'Table',  @level1name = Your Table Name,
@level2type = N'Column', @level2name = Yuur Column Name;

10-06 08:19
查看更多