当前位置:网站首页>PowerDesigner design name and comment replacement
PowerDesigner design name and comment replacement
2022-07-01 19:47:00 【Mischief 1124】
comment It's a comment .name Is the field description
stay PowerDesigner The operation is as follows
PowerDesigner-->Tools-->Execute Commands-->Edit/Run Scripts Next execution OK 了 .
hold comment Cover name The method is as follows :
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
Private sub ProcessFolder(folder)
On Error Resume Next
Dim Tab 'running table
for each Tab in folder.tables
if not tab.isShortcut then
tab.name = tab.comment
Dim col ' running column
for each col in tab.columns
if col.comment="" then
else
col.name= col.comment
end if
next
end if
next
Dim view 'running view
for each view in folder.Views
if not view.isShortcut then
view.name = view.comment
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
take name Cover comment The method is as follows
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
边栏推荐
- Bao, what if the O & M 100+ server is a headache? Use Xingyun housekeeper!
- How to configure webrtc video streaming format for easygbs, a new version of national standard gb28181 video platform?
- 实例讲解将Graph Explorer搬上JupyterLab
- 为什么一定要从DevOps走向BizDevOps?
- 使用 Kibana Timelion 进行时间序列分析
- qobject_cast用法
- brpc理解
- What is the essential difference between Bi development and report development?
- Basic knowledge of audio coding and decoding
- February 15, 2022: sweeping robot. There is a floor sweeping robot in the room (represented by a grid). Each grid in the grid has two possibilities: empty and obstacles. The sweeping robot provides fo
猜你喜欢
随机推荐
新窗口打开页面-window.open
JS ternary expression complex condition judgment
H264编码profile & level控制
Why must we move from Devops to bizdevops?
P2433 【深基1-2】小学数学 N 合一
Optaplanner learning notes (I) case cloud balance
703. 数据流中的第 K 大元素
ES6中的代理proxy
GB28181的NAT穿透
SIP protocol of gb28181
【无标题】
OpenCV视频质量检测--清晰度检测
ffmpeg 错误码
解决VSCode下载慢或下载失败的问题
ffmpeg 音频相关命令
Process steps of vibrating wire acquisition module for measuring vibrating wire sensor
Proxy in ES6
面试题篇一
Wechat applet navigator has a shadow after clicking. Remove the shadow effect of navigator
Graduation season | Huawei experts teach the interview secret: how to get a high paying offer from a large factory?