Nested PP code

PP code can be used in various places within PP commands

Within Index names

Index names can use PP code, so for example:

[*data dsSelect=First,Second,Third]

[*do lpSelect=1:[dsSelect.#]]

[*do lpAlpha=1:4]

[*set [dsSelect.lpSelect]My[&lpAlpha] = 0]

[*end lpAlpha]

[*end lpSelect]

Could be used instead of:

[*set FirstMyA = 0]

[*set FirstMyB = 0]

[*set FirstMyC = 0]

[*set FirstMyD = 0]

[*set SecondMyA = 0]

[*set SecondMyB = 0]

[*set SecondMyC = 0]

[*set SecondMyD = 0]

[*set ThirdMyA = 0]

[*set ThirdMyB = 0]

[*set ThirdMyC = 0]

[*set ThirdMyD = 0]

In arithmetic

For example:

[*set Value = [dsSet.#]+[dsSet.MyOne]]

In file names

For example:

[*data dsThisTime () CSV = [ThisCSV].CSV]

In ODBC sheet names and columns

For example:

[*dbloop dlRow = dfFile;’[ThisSheet]’;’[FirstCol]’,’[SecondCol]’]