MicroStrategy ONE
Adding data fields to documents
A data field is a text field that contains a reference to an object (metric, attribute, consolidation, or custom group) on a report. This reference is the object name inside braces { }. The braces indicate that the text fields are data fields, not static text. In Design View, data fields for the Employee attribute and the Revenue metric look like the following:
{Employee} {Revenue}
When the data fields shown above are displayed in PDF View, the attribute elements and revenue values are displayed, as shown below:
Ellerkamp:Nancy $847,227
Gale:Loren $1,669,290
Tomison:Mary $1,690,350
Zemlicka:George $822,500
If the object referenced by a data field is removed from the dataset report, the data field will become static text when the PDF is created.
You can add data fields in any of the following ways:
-
Drag and drop a dataset object onto any section of the Layout area. A text field containing a reference to the dataset object is added to the document.
-
Insert a blank text field in any section of the Layout area, then type the reference to the dataset object in the text field.
-
Create a metric within the document, which creates a text field containing a reference to the metric. The value of a metric, whether it is created in the document or is a dataset object, is calculated differently depending on its location in the document, as described in Metric calculation in documents.
The following procedure describes the first two methods in more detail. For descriptions of the different kinds of metrics that you can create, and links to procedures to create them, see Creating metrics in documents.
The following procedure adds a data field to a document in the Document Editor, but you can also add data fields when you create a document with the Document Wizard. The objects you choose on the Select fields for the document page are displayed in the Layout area of the document when the wizard is complete.
To add a data field
-
Open the document in the Document Editor. How?
-
Expand the section where you want the data field by clicking the plus sign next to the section name.
-
Do one of the following:
-
Add a dataset object.
-
Select the object from the objects displayed in the Datasets pane.
If the Datasets pane is not displayed, click Datasets at the bottom of the panel on the left. If the panel is not displayed at all, select Datasets from the View menu.
-
Drag and drop the selected object into the Layout area.
-
Each text field is automatically placed within square brackets [ ] when you drop it in the Layout area. After you save and re-open the document, the brackets remain only if the object name contains special characters. A special character is any character other than a - z, A - Z, 0 - 9, #, _, and . (period). This ensures that data fields are resolved correctly when the PDF is displayed in a language other than English.
-
When you add a metric to the document, the dataset name is added to the string if the metric exists in multiple datasets.
-
Type the object's name.
-
-
From the Insert menu, select Text. When you move the cursor to the Layout area, the pointer becomes crosshairs.
-
Click in the desired section of the Layout area. If you click and drag in the section, you can size the text field.
-
Type the object's name within braces (that is, { }). If the metric exists in multiple datasets, use the format {[dataset name]:[metric name]}. (Do not associate an attribute with a specific dataset, as attribute elements come from the joined datasets.) If the name has spaces or special characters, type it in brackets (that is, [ ]) within the braces.
A special character is any character other than a – z, A – Z, 0 – 9, #, _, and . (period).
-
Press Enter when you have finished.
-
You can also resize the text field, if needed. How?
-