Go
if exists (select * from sysobjects where id = OBJECT_ID('[CustomerDemographics]') and OBJECTPROPERTY(id, 'IsUserTable') = 1) 
	DROP TABLE [CustomerDemographics]
Go

CREATE TABLE [CustomerDemographics] (
CustomerTypeID  nchar NOT NULL,   -- 客户类型ID
CustomerDesc    ntext NULL        -- 客户描述

CONSTRAINT [PK_CustomerDemographics] PRIMARY KEY CLUSTERED ([CustomerTypeID])
)
--添加表注释
exec sp_addextendedproperty N'MS_Description', N'客户统计', N'user', N'dbo', N'table', N'CustomerDemographics'

--添加列注释
exec sp_addextendedproperty N'MS_Description', N'客户类型ID', N'user', N'dbo', N'table', N'CustomerDemographics', N'column', N'CustomerTypeID'
exec sp_addextendedproperty N'MS_Description', N'客户描述', N'user', N'dbo', N'table', N'CustomerDemographics', N'column', N'CustomerDesc'
