1。首先copy以下的vbs脚本。并将其另存为name2comment.vbs

'******************************************************************************
'* File: name2comment.vbs
'* Title: Name to Comment Conversion
'* Model: Physical Data Model
'* Objects: Table, Column, View
'* Author: steveguoshao
'* Created: 2013-11-29
'* Mod By:
'* Modified:
'* Version: 1.0
'* Memo: Modify from name2code.vbs
'****************************************************************************** Option Explicit
ValidationMode = True
InteractiveMode = im_Batch Dim mdl ' the current model ' get the current active model
Set mdl = ActiveModel
If (mdl Is Nothing) Then
MsgBox "There is no current Model "
ElseIf Not mdl.IsKindOf(PdPDM.cls_Model) Then
MsgBox "The current model is not an Physical Data model. "
Else
ProcessFolder mdl
End If ' This routine copy name into comment for each table, each column and each view
' of the current folder
Private sub ProcessFolder(folder)
Dim Tab 'running table
for each Tab in folder.tables
if not tab.isShortcut then
tab.comment = tab.name
Dim col ' running column
for each col in tab.columns
col.comment= col.name
next
end if
next Dim view 'running view
for each view in folder.Views
if not view.isShortcut then
view.comment = view.name
end if
next ' go into the sub-packages
Dim f ' running folder
For Each f In folder.Packages
if not f.IsShortcut then
ProcessFolder f
end if
Next
end sub

2,在PowerDesigner 的选择以下的菜单

watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvam9leW9uMTk4NQ==/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/SouthEast" alt="">

3,然后选择name2comment.vbs文件,run就可以

PowerDesigner 将表的字段name属性设置到comment凝视的更多相关文章

  1. 不允许修改SQLserver2008r2表中字段的属性问题

    SQLserver2008r2修改表中字段的属性时弹出 点击工具->选项,取消阻止保存要求重新创建表的更改

  2. Mysql 整数类型的字段的属性设置及常用的函数

    数据类型 二.MySQL支持的数据类型 数值类型.日期类型.字符串类型 1.数值类型 1)整数类型 tinyint.smallint.mediumint.int和bigint 2)zerofill属性 ...

  3. powerdesigner 将表中name列值复制到comment列 (保留原有comment)

    /** * PowerDesigner里面将表中name列值复制到comment列 * @see --------------------------------------------------- ...

  4. EF中多表公共字段,以及设置EntityBase使所有实体类继承自定义类

    使用EF框架访问数据库时,如果某些表具有公共字段,例如在审核流程中,对于各类申请单资料的创建人.创建时间.修改人.修改时间,这些可能多表都需要的字段,如果在每个实体中进行赋值操作显然是类似和重复的,下 ...

  5. mysql给一张表新增字段,并设置该字段为外键

    首先给usercategory表新增libraryid字段: alter table usercategory add libraryid varchar(50) 修改picturelibrary表的 ...

  6. PowerDesigner跟表的字段加注释

    选择那个表 右键- >Properties- >Columns- >Customize Columns and Filter(或直接用快捷键Ctrl+U)- >Comment( ...

  7. mysql修改表、字段、库的字符集(转)

    原文链接:http://fatkun.com/2011/05/mysql-alter-charset.html MySQL中默认字符集的设置有四级:服务器级,数据库级,表级 .最终是字段级 的字符集设 ...

  8. Oracle | 给表和字段添加注释

    comment  on  column  表名.字段名   is  '注释内容'; comment on column OPERATOR_INFO.MAIN_OPER_ID is '归属操作员'; c ...

  9. .NET开源工作流RoadFlow-表单设计-新建表单(属性设置)

    点击表单设计工具栏上的 新建表单 按钮会弹出新表单属性设置框: 表单名称:新表单表名称. 数据连接:表单对应的数据库连接(此连接在 系统管理-->数据库连接 中维护). 数据表:表单对应的数据库 ...

随机推荐

  1. poj 3230(初始化。。动态规划)

    Travel Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 4353   Accepted: 1817 Descriptio ...

  2. 准备开发开放API接口

    准备开发APP开放接口,允许JQUERY直接调用http://blog.csdn.net/wuxiangege/article/details/52238968 SIGN的设计与实现http://bl ...

  3. C3P0连接池一些基本配置

    C3P0连接池配置 数据库连接是一个耗费大量资源且相当慢的操作,所以为了提高性能和连接速度,诞生了连接池这样的概念. 在多用户并发操作过程中,连接池尤为重要. 它是将那些已连接的数据库连接存放在一个容 ...

  4. 计蒜客 30990.An Olympian Math Problem-数学公式题 (ACM-ICPC 2018 南京赛区网络预赛 A)

    A. An Olympian Math Problem 54.28% 1000ms 65536K   Alice, a student of grade 66, is thinking about a ...

  5. 位运算和enum中的位运算

    1.位逻辑非运算 ~ 位逻辑非运算是单目的,只有一个运算对象.位逻辑非运算按位对运算对象的值进行非运算,即:如果某一位等于0,就将其转变为1:如果某一位等于1,就将其转变为0. 比如,对二进制的100 ...

  6. Python RE模块中search()和match()的区别

    match()函数只检测RE是不是在string的开始位置匹配, search()会扫描整个string查找匹配: 也就是说match()只有在0位置匹配成功的话才有返回, 如果不是开始位置匹配成功的 ...

  7. python3 开发面试题(装饰器必须考)6.4

    def f(): print("2018-06-04") # 每次调用f的时候 在打印"2018-06-04" 之前打印一句 开始, 之后再打印一句 结束 de ...

  8. [CSAcademy]Connected Tree Subgraphs

    题目大意: 给你一棵n个结点的树,求有多少种染色方案,使得染色过程中染过色的结点始终连成一块. 思路: 树形DP. 设f[x]表示先放x时,x的子树中的染色方案数,y为x的子结点. 则f[x]=pro ...

  9. 高性能mysql读后感

    1. 事务里的写操作,四种隔离级别,都会加排他锁. 2. 事务里的读操作,前三种隔离级别,不会加锁,最后一种隔离级别,会加共享锁. 3. 上面的写.读操作,都是隐式加的锁.  可以自己显示对读操作进行 ...

  10. spring融合activitymq-all启动报错的解决办法

    报错信息: nested exception is java.lang.NoSuchMethodError: org.springframework.core.annotation.Annotated ...