Data sets have the following fields:
- Description: The description of the data set, this is only relevant as documentation.
OQL query: The OQL query which defines the data set.
Java action: The interface of the Java action which returns a data set. The columns and data types of the columns need to be specified in the Desktop Modeler. Based on this specification the Desktop Modeler will create a template for this action.
The following shows an example OQL query that calculates the aggregated total order amount for all orders of a customer for a specific group of customers:
FROM CRM.Customers As CustomerObj INNER JOIN CustomerObj/CRM.Orders_Customer/CRM.Orders As OrderObj WHERE CustomerObj/CRM.Customer_Group = $ParGroup GROUP BY CustomerObj/Name SELECT CustomerObj/Name As Name, SUM(OrderObj/TotalAmount) As TotalAmount
A dataset can have multiple parameters. Parameters are used to filter / manipulate data sets. Security on data sets is configured based on the parameters. In a Java action, the parameters are used in the generated template.
In OQL, parameters can be called using a $ symbol, for example: $Month.
A parameter has the following configurable properties:
Name: The name of the parameter
Type: The type of the parameter: Object, Enumeration or a primitive (e.g. DateTime, Float, Integer, Boolean, etc). See Data Types for the possible parameter types.
Constraints: The constraints on a parameter. These constraints influence which values can be selected for parameter input values by the end user. Constraints can be associated with user roles in the data set security. There are two type of constraints: ranges which apply to numeric and date parameters and XPath constraints which apply to object parameters.
Ranges: When a parameter is defined as a range the drop-down box in the report shows each range instead of all values within the ranges. Currency (deprecated), float (deprecated) and decimal parameters are always ranges.