Show all
Purpose
You can report on data from multiple classes or tables by defining, for each class other than the Applies To class for your report, a join that describes how to match or pair each instance of the Applies To class to each instance of the other class (the joined class). This involves defining a logical condition, like a filtering condition, that equates properties in the two classes. For example:
MyOrg-CustomerService-Work.ProductID Is Equal MyOrg-Sales-Data-Products.SKU
A special case of this involves accessing a declarative index that has been built from the class on which you are reporting. A declarative index is often used to access embedded properties of an object. It uses an Index- class defined by a Rule-Declare-Index rule to store embedded properties in a separate database table, in such a way that this table can be easily joined to the data you are reporting on.
Note that when you define a join from one class to another, the report results may include multiple entries for each work object, if these are multiple corresponding entries in the other class or table.
Use the Data Access tab for general report sourcing information, such as limits on how long a report will be allowed to run and how many rows of data it can retrieve.GATZH updates 3/23/2010
Use the Data Access tab to define security information for the report.
Class Joins
Field
|
Description
|
Prefix
|
Enter a short text string to be used as an alias for the joined class and all its properties. The Prefix is assigned to all the properties in the class and used to reference the properties from these fields on other tabs in the rule form.
|
Class Name
|
Select a class to be the primary class for the join. The Prefix plus this class name specify the joined class. You can specify multiple primary classes to be joined.
If this work type is derived from Work-, choose carefully whether you want to join to an implementation class, or to a framework class. |
Edit Conditions
|
Click to open the Enter Join Conditions window and specify properties of the class, join conditions, and values.
Complete the fields in the window:
Field
|
Description
|
Label
|
Enter a text label to identify the condition in this row. The label is used in the Logic fields to combine conditions into a single location. |
Column
|
Select a property associated with the class you have specified in the Class Joins tab. This property must be an exposed column. |
Relationship
|
Select Is Equal . |
Value
|
Select the property in the report's Applies To class that corresponds to the Column value entered above. |
Conditions
|
In the text box at the top Using the values entered in the Label field, enter a logical expression that defines how the system combines the criteria into an overall logical condition at runtime. The expression can include parentheses and the operators AND or OR.
For example, if the table contains four rows labeled, A, B, C, and D, you can enter: (A OR B OR C ) AND D
in this field. This notation is the same as for the logic statement in when condition rules.
|
|
Type
|
Accept the default choice, Only include matching instances , to cause the report to only include instances in each class that have a matching instance in the other class (referred to in database terms as an inner join).
By choosing one of the other options , you can instead use an outer join for the report in which all instances of one of the classes are included in the report even if they have no matching instances in the other class:
- Select
Include all rows in <class> to cause the report output to include all qualifying instances of the Applies To class of the rule, even if there is no match found in the prefix class.
- Select
Include all rows in <prefix> to cause the report output to include all qualifying instances of the joined class (identified by the value of the Prefix field), even if there is no match found in the Applies To class.
|
Declarative Index Joins
You can specify indexes created by Rule-Declare-Index rules here to reference embedded properties from the Applies To class. This facilitates using Rule-Declare-Index rules for performance by avoiding retrieving properties from the BLOB (Storage Stream) column. You can attach an alias to any declarative index that you have previously defined.
Field
|
Description
|
Prefix
|
Enter a text string to be used as an alias for the joined declarative index class and all its properties. The prefix is assigned to all the properties in the class and used to reference these properties on other tabs of the rule form.
|
Index Name
|
Select the Index- class created by the Declare Index rule.
|
Type of Join
|
Optional. The default choice, Only include matching instances, indicates that the report will only include instances in the Applies To class that have a matching instance in the declarative index (referred to in database terms as an inner join). By choosing the other option here, you can instead use an outer join for the report, in which all instances of the Applies To class are included in the report, even if they have no matching instances in the declarative index.
|
Associations
This read-only area lists any association rules that support the report, based on the properties you entered on the Design tab. Association rules are linked to report definition rules automatically, as needed. See About Association rules and Pega Developer Network article PRKB-26153 When and how to create an association rule to support reporting.
General Data Source Settings
Field
|
Description
|
Report Source
|
|
Maximum Number of Rows to Retrieve
|
Optional. Enter a maximum number of instances to retrieve for the report contents. As a best practice during testing, accept the default value 500 . If you leave this blank, the system enforces a limit of 10,000 .
If you exceed the max rows limit, the rows that have been retrieved are displayed, and the report header displays how many rows there are. No error dialog or error message is shown, and no error is written to a log. GATZH 4/1/2010
You can set another default value for this field. Override the default model named Rule-Obj-Report-Definition.pyDefault and set the initial value of property pyContentSource.pyMax to the desired limit.
|
Maximum Elapsed Time in Seconds
|
Optional. Enter the maximum elapsed time in seconds that the report execution is allowed to run before being interrupted. If you leave this blank, the system enforces a limit of 60 seconds.GATZH updates 3/23/2010
If you exceed the maximum elapsed time, a dialog appears explaining that the report took too long to run and that the filter conditions must be more specific. A report runs faster by adding additional filter conditions, or making the existing ones more constrained.GATZH 4/1/2010
|
Security
Field
|
Description
|
Privilege
|
Optional. Use SmartPrompt to select security privileges required to run this report. |
About Report Definition
rules