Defining Generation and Reverse-Engineering of New Metaclasses

You can extend your DBMS to include new metaclasses that are not present in the standard PowerDesigner metamodel. Many DBMSs contain such metaclasses, which are defined by creating a stereotype on an existing metaclass, and you can also create your own. To include these objects in generation and reverse-engineering, you must add them to the Script/Objects category, and define appropriate SQL statements and queries.

  1. Create a new metaclass in your DBMS definition file by defining a new stereotype on an existing metaclass and selecting the Use as metaclass option (see Creating New Metaclasses with Stereotypes).
  2. Define appropriate extended attributes (see Extended Attributes (Profile)) and other extensions as appropriate to accurately define the nature of your object.
  3. Right-click the Script/Objects category, select Add Items, select your new object in the list, and then click OK to add it to the category.
  4. Right-click the new object entry, and select Add Items to add the necessary script items to it. As a minimum, to enable the generation and reverse engineering of the object, you must add the following items:
    • Create
    • Drop
    • AlterStatementList
    • SqlAttrQuery
    • SqlListQuery
  5. Click OK to add these script items to your object, and enter the appropriate SQL statements and queries. You will need to enter values for each of these items. For guidance on syntax, see Common Object Items.
  6. [optional] To control the order in which this and other objects will be generated, use the Generation Order item (see Script/Objects Category (DBMS)).