Formatting Options

You can change the formatting of variables by embedding formatting options in variable syntax as follows:

%.format:variable%

The variable formatting options are the following:

Format

option

Description

n

Extracts the first n characters. Blanks or zeros are added to the left to fill the width and justify the output to the right

-n

Extracts the last n characters. Blanks or zeros are added to the right to fill the width and justify the output to the left

L

Converts to lowercase characters

U

Converts to uppercase characters

c

Upper-case first letter and lower-case next letters

A

Removes indentation and aligns text on the left border

D

Returns the human-readable value of an attribute used in the PowerDesigner interface when this value differs from the internal representation. In the following example, the value of the Visibility attribute is stored internally as "+", but is displayed as "public" in the property sheet: %Visibility% = + %.D:Visibility% = public

F

Applies case conversion to the first character only. Used with L or U.

T

Leading and trailing white space trimmed from the variable

q

Surrounds the variable with single quotes

Q

Surrounds the variable with double quotes

X

Escapes XML forbidden characters

E

[deprecated – use the ! power evaluation operator instead, see Operators]

You can combine format codes. For example, %.U8:CHILD% formats the first eight characters of the code of the CHILD table in uppercase letters.