The solution of column annotation in PowerDesigner reverse engineering when generating PDM

Source: Internet
Author: User
Tags powerdesigner

When using PowerDesigner reverse engineering to generate PDM, column annotations (columncomment) are never generated, after several hours of exploration, find a compromise method, now share the following. And hope that there is a better way to guide the master.

The month of invitation is PowerDesigner 15.2, the database is SQL Server 2008 R2

The method is as follows:

1, in the PowerDesigner interface-file-reverse engineer-database, and then select a DBMS, I select a system by default SQL Server 2008 DBMS modified by the Sql_2008_ Mydefine.

Choose ODBC, enter the correct connection string, select the database and table.

Build effect: Name is English and comment column is empty.

And what we want is name listed in Chinese, comment for Chinese.

Looking at the next online help, we found the value under Sql_2008_mydefine::script\objects\column\sqllistquery as follows:

View Code

{OWNER, TABLE, S, COLUMN, Dttpcode, LENGTH, SIZE, PREC,
       
       COMPUTE, Notnull, IDENTITY, DOMAIN, DEFAULT  , Extidentityseedinc, COMMENT, Extcollation, Extidtnotforreplication, Extdeftconstname, Sparse, FileStream, Extrowguidcol}

Select
U.name,
O.name,
C.COLUMN_ID,
C.name,
Case when c.system_type_id in (165,167,231) and c.max_length =-1Then T.name + ' (Max) ' else T.name End,
C. Precision,
Case (C.max_length) when-1Then0else case when c.system_type_id In ( the,231,239) Then (C.max_length/2) Else (c.max_length) end As Colna,
C.scale,
Case (c.is_computed) when1 Then convert (

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.