1.在physical的状态下
2.鼠标右键点在左边的tables上new一个表,取表明为table1(comment设为“表格1”),添加一个字段为ID(comment设为“字段1”)
3.鼠标右键点在new的表上,选择table properties,comment
4.在弹出的sql server tables的对话框中,的Owner中填上“dbo”
5.选择菜单tools--》firword engineer--》schema genaration
6.默认是Option选中,点击Option中的最后一个other Option,
7.在右边的对话框中选中comments,这是他会自动勾选Owner
8。点击按钮Preview得到如下代码
CREATE TABLE dbo.table1
(
ID char(18) NULL
)
go
exec sp_addextendedproperty 'MS_Description' , '表格1' , 'user' , 'dbo' , 'table' , 'table1'
go
exec sp_addextendedproperty 'MS_Description' , '字段1' , 'user' , 'dbo' , 'table' , 'table1', 'column' , 'ID'
go