You can display text in the feature class form that is queried with an SQL statement. The following example shows how to display the label text that is stored in the label feature class directly in the parent feature class form.
- In the Infrastructure Administrator, do one of the following:
- Click Enterprise and connect to the enterprise industry model. Open a project.
- Click File and open an industry model drawing or template.
- Expand the Industry Model node and click Form Designer.
The form designer is displayed in the right pane. The topics and feature classes are displayed in the form explorer.
- In the form explorer, select a feature class, select the Form Type, such as Default, and click Edit.
- In the Designer dialog box, on the designer toolbar, click the Editable SQL Text Box icon.
- Click OK for the name.
- In the left pane, click the Properties tab and do the following:
- Select the DetailTable property, click and select the feature class.
- Select the DetailAttribute property, click and select the attribute.
- Select the DetailFilter property and click to open the SQL Assistant.
- In the SQL Assistant dialog box, under Relations, expand the feature class nodes and click the detail feature class that contains the information you want to display. The SQL expression is inserted into the expression input box.
select * from DOC_GREENSPACE where FID in (select FID_GREENSPACE from DOC_TREE where fid={fid})
- In the expression input box, delete the first part of the select statement including the WHERE. The result is:
FID in (select FID_GREENSPACE from DOC_TREE where fid={fid})
- Click Execute to run the SQL statement, and to check the syntax.
- Click OK to exit the SQL Assistant.
- Select the DetailFilter property again, and click .
The expression input box shows how the select statement has been put together from the three parts. The select statement result is shown in a text box. If a user modifies this value, the related table is updated.