Common Methods of powerdesigner)

Source: Internet
Author: User
Tags powerdesigner

Modify foreign key naming rules

Choose database> edit current DBMS.
Select scripts-> objects-> reference-> constname
The value on the right is:

FK _ %. u8: child % _ %. U9: refr % _ %. u8: parent %

It can be seen that the naming method is: 'fk _ '+ 8-seat table name + 9-digit reference name + 8-digit parent table name. You can customize the following mode:

FK _ %. u7: child % _ relations _ %. u7: parent %,

You can change the FK name to fk_table_2_relations_table_1.
After mastering this method, you can modify it according to your own ideas.

The header comment in the SQL file of the database creation script is annoying. You can select the options card in the Databse-> Generate database (CTRL + G) window and remove the usage title hook option.

Add foreign key
Model-> references: Create a foreign key and double-click it to enter the foreign key attribute. In the "joins" card, select the foreign key field of the sub-table.

How to achieve non-automatic equality of name and code
When you create an entity in CDM, the name and Code do not automatically match

Set tools -- gerneral options ---> dialog ----> name to code signing ing

-------------------------------------

How to display the name column in scrip

Modify the field generation rule. To add a comment for each field, expand the value of script-> Object-> column-> Add in the same window:

% 20: column % [% compute %? As (% compute %): % 20: datatype % [% identity %? % Identity %: [% null %] [% notnull %] [Default % default %]
[[Constraint % constname %] Check (% constraint %)]/* % colnname % */

% Colnname % indicates the column name value (which can be Chinese)

---------------------------------------------------------------------------------

Settings of powerdesigen auto-increment Columns

In PDM, view the table attributes. On the columns tab, select the entire column and view the column attributes. Click the properties icon in the upper-left corner (the one with a hand-shaped pattern). A setting window is displayed, in the General tab.
On the General tab of the column attribute, there is an identity check box. Just click it.

--------------------------------------
1. How to create an index under powerdesigner
2. How to create an auto-increment column under powerdesigner
3. How to check the design model under powerdesigner

1. How to create an index under powerdesigner
1. Double-click the table design drawing and click "Table properties". On the tab page, select "indexes ".

2. Click the attribute of the new index. indexex properties is displayed.

3. Add an index Field

2. How to create an auto-increment column under powerdesigner
2. Use the following statements in the sqlserver database to complete
In the table creation statement, add the following
Identity (1, 1)
You can also use the following statement to reset the auto-incrementing seed.
DBCC checkident (configsys, reseed, 0 );
3. How to check the design model under powerdesigner
1. Select Tools-check model in the menu bar, as shown in figure

2. Select each setting to be checked.

3. Confirm and check the summary of the results.
 

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.