Defining Listing Fields
This chapter describes how to add individual listing fields to a cube. With individual listing fields, users can create custom listings in the Analyzer. This chapter discusses the following topics:
Also see the chapter “Defining Listings.”
Also see “Accessing the Samples Shown in This Book,” in the first chapter.
About User-Defined Custom Listings
The purpose of individual listing fields is to enable users to define custom listings in the Analyzer. This process is described in “Creating a Custom Listing” in Using the Analyzer, but the following steps provide a summary:
To start, the user displays the default listing.
The user selects Detail Listings in the left area of the Analyzer.
The user then expands the Custom Listing folder. For example:
The user can then drag listing fields from this area to the Custom Listing Fields box. the system then executes the listing query and displays the results.
Creating a Listing Field
To create a listing field:
Click Add Element.
The system displays a dialog box.
For Enter New Item Name, type a listing name.
See “Names for Model Elements,” earlier in this book.
Select the listing name in the Model Viewer, in the Listing Fields section.
Optionally specify the following details:
Display name — Localizable name of the listing field. If you do not specify this, the user interface instead displays the logical name.
Description — Description of the listing field.
Field Expression — SQL expression that refers to a field in the source table or (via arrow syntax, for example) to a field in a related table. The following example (from the Hole Foods Sales cube) uses arrow syntax:
(Product->Category)Copy code to clipboard
If you do not specify an alias, you must put parentheses around the expression as shown here.
If you do specify an alias, the parentheses are not required. For example:
Product->Category CategoryCopy code to clipboard
Resource — Specify the resource that secures the listing field.
For information on how this is used, see “Setting Up Security” in Implementing InterSystems Business Intelligence.
In Field Expression, you can use SQL functions, including InterSystems SQL functions such as %EXTERNAL. When a user creates a custom listing in the Analyzer, the system creates an SQL SELECT statement that contains a comma-separated list of the Field Expression of the selected listing fields.
You can specify an SQL alias within Field Expression. However, if you do so, Display name is ignored and the field name cannot be localized.
You can also create a listing field via drag-and-drop action. To do so, drag a field from the left area and drop it onto the Listing Fields heading. Then select the new listing field and make any needed edits in the right-hand area.
You can also drag a different source field and drop it into Field Expression. If you do so, the value there is replaced with the new field.