2010-11-10

PowerDesigner TableComment 筆記

變更 TableComment Script 筆記。

路徑:MSSQLSRV2000::Script\Objects\Table\TableComment

[%OWNER%?[.O:[execute ][exec ]]sp_addextendedproperty [%R%?[N]]'MS_Description', 
   [%R%?[N]]N%.q:COMMENT%,
   [%R%?[N]]'user', [%R%?[N]]%.q:OWNER%, 
   [%R%?[N]]'table', [%R%?[N]]%.q:TABLE%
:declare @CurrentUser sysname
select @CurrentUser = user_name()
[.O:[execute ][exec ]]sp_addextendedproperty [%R%?[N]]'MS_Description', 
   [%R%?[N]]N%.q:COMMENT%,
   [%R%?[N]]'user', [%R%?[N]]@CurrentUser, 
   [%R%?[N]]'table', [%R%?[N]]%.q:TABLE%
]

PowerDesigner

沒有留言: