You are viewing the documentation for Blueriq 16. Documentation for other versions is available in our documentation directory.
What does it do?
AQ_Aggregate_Search retrieves the Aggregate Id(s) belonging to the found aggregates and stores this in an attribute, ready for use by (for example) Service call type: AQ_Aggregate_Read.
Service call definition:
Aggregate definition:
Parameters
Parameter | Direction | Value | Description | Required |
---|---|---|---|---|
Aggregate type | Input | Module element Aggregate | Select the aggregate type to search. | Yes |
Target entity | Output | Entity | Select an entity in which you want to store the aggregate ID and version. If this entity is a singleton, no instances will be created and the next two parameters will be used to contain Id and version of the found aggregates. If this entity is a multiton, an instance is created for each found aggregate and the next two parameters will contain single values. Instances of the specified multiton are deleted before the search is run. Each search is performed with a clean slate. | Yes |
Target attribute for aggregate Id | Output | Attribute of target entity | Select an attribute of the target entity on which attribute you want to store the found aggregate Id. This attribute can be singlevalued or multivalued. | Yes |
Target attribute for version Id | Output | Attribute of target entity | Select an attribute of the target entity on which attribute you want to store the found version Id. | No |
Only search for latest versions | Input | Checkbock, checked by default | Check when only latest versions of versioned aggregates are searched. | No |
Maximum results | Input | Integer | The maximum number of results, the system will stop after reaching this number. | No |
Search criteria | Input | Standard and custom metadata fields | Specify the search criteria, based on standard and custom metadata fields. | Yes |
When searching for aggregates with versions, placing the found aggregate Id's in a multivalued attribute of a singleton and placing the found version Id's in another multivalued attribute of that singleton results in an information gap: it cannot be reproduced which version Id's belong to which aggregate Id's. Therefore, it is possible to let Blueriq create an instance for each found aggregate. See How to search for aggregates.
Search criteria
The search criteria are all triples that adhere to the pattern <metadata><operator><value>. The value can be single or multi, depending on the operator. See the list below.
Operator | Used with metadata of type | Value can be |
---|---|---|
Equals | All single-valued datatypes | Single value |
Not equals | All single-valued datatypes | Single value |
Less than | All single-valued datatypes | Single value |
Less than or equals | All single-valued datatypes | Single value |
Greater than | All single-valued datatypes | Single value |
Greater than or equals | All single-valued datatypes | Single value |
Like | String | Single value |
Not like | String | Single value |
In | All multivalued datatypes | Multivalued |
Not in | All multivalued datatypes | Multivalued |
Events
This service uses two events for a commit and one for an exception:
FoundNoAggregates:
typically this node will go to a page with a not-found-message and is of type Rollback.FoundOneAggregate
: typically this node will continue in flow with the found aggregate and is of type CommitSkipSkipValidate (default exit).FoundMultipleAggregates
: typically this node will result in an aggregate list containing all found aggregates and is of type CommitSkipValidate.Unauthorized
: This exit is triggered when the user does not have one of the roles that is set on the aggregate definition.
Tracing
Searching aggregates is not traced, just like reading aggregates (using Service call type: AQ_Aggregate_Read).