Example: “If exists ()” Syntax in Repeat Region
The following is an example of using the “if exists” syntax.
Create a repeat region in Drawing for assembly ASM001 with the following structure:
Part PRT001 contains parameter overridename with value over ridden name.
Part PRT002 does not contain any parameter.
If you have overridename parameter name in any of the parts and want to show the value of this parameter name in the repeat region and for parts without overridename parameter name, show the value from asm_mbr_name, do the following:
1. Create a table with repeat regions. In the drawing, click Table > Repeat Region. Create a repeat region and enter the following report symbols using the Report Symbol dialog box to display the results in the report table. See To Enter Report Parameters into a Repeat Region and To Define Repeat Regions
rpt.index—Displays the index.
asm.mbr.name—Displays the name of the part.
rpt.rel.user_defined— Enter user defined parameter name bomname. This is a repeat region level user defined parameter. It is not necessary to include this parameter in the parts.
2. Create a local parameter. Click Table > Repeat Region. On Menu Manager, under TBL REGIONS, click Relations and click any cell containing text. The Relations dialog box appears. In the Relations dialog box add a local parameter asm_mbr_overridename. Click OK.
* 
You must add this parameter before you define the relation.
3. Use if exists to create a relation. On Menu Manager, under TBL REGIONS, click Relations again and enter the relation as below and verify the relation:
bomname = asm_mbr_name
if exists ("asm_mbr_overridename")
bomname = asm_mbr_overridename
endif
4. Update the table. On Menu Manager, under TBL REGIONS, click Update Tables to update the repeat region table. The resulting updated report table will look like as below: