Input Nodes
About Input Nodes in Family Policies
Input nodes represent various items and values that you can use as inputs to the policy logic.
Because Input nodes provide successor nodes with values to evaluate, the first node in a policy model must be an Input node.
Input Nodes
Constant Nodes in Family Policies
A Constant node is an Input node that represents a specific value that does not change from one policy execution to another. You can use a Constant node for input values that are used in multiple places in the policy model.
The output of a Constant node is the value that you specify in the Value section of the node's Properties window.
Node Properties
The Properties window for a Constant node contains the items that are described in the following table.
Item |
Description |
Notes |
---|---|---|
Data Type list |
Specifies the type of data that the node represents. |
This property is not required, but it is highly recommended to select a value. This minimizes the chance of the Constant node result either being misinterpreted during the policy execution and the validation, or being displayed in an incorrect format while viewing the execution and the validation results. |
Value box |
Specifies the value that the node represents. |
If the data type for the Constant node is a Data Frame, then, on the Properties window, <DATAFRAME> appears in the Value box. You can select to access the Edit Data Frame window, in which you can view the Data Frame or configure its input values. |
Current Entity and Current Relationship Nodes in Family Policies
Current Entity and Current Relationship nodes are Input nodes that represent the APM entity or relationship family, respectively, that is associated with the family policy. You can use these nodes to access information that is stored in the record whose changes triggered the family policy.
- Any field in the record that triggered the family policy
- The following system fields in the family of the record that triggered the family policy:
- Created By User Key
- Created Date
- Entity Key
- Entity ID
- Family Key
- Last Updated By User Key
- Last Updated Date
- Site Key
- Any field in the record that triggered the family policy
- The following system fields in the family of the record that triggered the family policy:
- Created By User Key
- Created Date
- Entity Key
- Entity ID
- Family Key
- Last Updated By User Key
- Last Updated Date
- Predecessor Family Key
- Predecessor Key
- Relationship Definition Key
- Site Key
- Successor Family Key
- Successor Key
- The Current Entity node is available only for family policies associated with entity families and the Current Relationship node is available only for family policies associated with relationship families.
- There can be only one Current Entity or Current Relationship node in a single family policy.
Node Properties
Other than optionally specifying a name for the node, there are no properties to configure for a Current Entity or Current Relationship node.
Current Entity or Current Relationship nodes are often the starting point in policy models because they provide successor nodes with fields to evaluate. For example, consider an AfterUpdate family policy belonging to the Work History entity family. Using a Current Entity node, you could configure a policy such that, when the policy is triggered by a change in a Work History record, successor nodes evaluate whether or not the value in the Work Order Status field of the corresponding record has changed. If it has, the policy sends an email message to notify users of the change. In addition, the policy updates the related Recommendation record to reflect the new status of the work order.
Previous Entity Nodes in Family Policies
A Previous Entity node is an Input node that you can use in a Before Update family policy to determine whether a value in a certain field will change in the transaction that triggered the family policy.
Node Properties
You can specify the name for the Previous Entity node; no other properties are available.
The Previous Entity Node
The following example illustrates how you can use the Previous Entity node to send an email notification if the Product value in a Measurement Location changes.Current User Nodes in Family Policies
A Current User node is an Input node that represents information associated with the currently logged in APM user (i.e., the user who makes the change that triggers the family policy).
- Any field in the Security user or Human Resource record for the logged in user.
- The following system fields in the Security User record for the logged in user: Entity Key, Family Key, and Entity ID.
Node Properties
Other than optionally specifying a name for the node, there are no properties to configure for a Current User node.
Current User node
The following example illustrates how you can use the Current User node to access the current user's email address, which exists in the Human Resource family, and their User ID, which exists in the Security User family. Consider the following nodes and connections.
In this example, a Current User node named Engineer is connected to an Email Contact node and a Create Recommendation node.
As shown in the following image, you can use the Properties window for the Email Contact node to select the Current User node and the Email Address field in the Human Resource family.
Additionally, as shown in the following image, you can use the Properties window for the Create Recommendation node to select the Current User node and, in this case, the User ID field in a field in the Security User family.
Query Nodes in Family Policies
A Query node is an Input node that represents a query that is stored in the APM Catalog. You can use a Query node to access the results of a specific query. The query will run each time the policy is executed so that the latest results are used in the policy execution. If the specified query contains prompts, you must use the node's Properties window to identify the values that should be provided to the prompts.
A Query node generates the following outputs:
- Result Set, which represents the results of the specified query. This output can be used only with successor nodes that are capable of handling collections.
- Any value in the top row of the specified query.
- The Result Set is restricted to the first 10000 rows of the query results.
Node Properties
The Properties window for a Query node contains the items that are described in the following table.
Item |
Description |
Notes |
---|---|---|
Query Path |
Specifies the path to the query that will run when the policy is executed. |
You can select the switch to field input () button to select an input from another node. You can select the show the constant field input () button to select an output of a predecessor node in this section. Note: When the query path is sourced from a predecessor node, the results collection output from the query node can be used only when you do not need to select a specific column in the collection.
You can enter the path manually, or you can browse to the query by selecting . The query that you choose must have an ID and a caption. |
Query section |
Provides values to any query prompts. |
One Query section appears for each prompt in the selected query. The label that appears after Query: identifies the prompt caption. You can select to specify the output of a predecessor node in this section. |
Query Entity Nodes in Family Policies
- Any field in the entity that the Query Entity node represents.
- The following system fields for the entity that the Query Entity node represents: Entity Key, Entity ID, Family Key, and Site Key.
Node Properties
Item | Description | Notes |
---|---|---|
Entity Key | Specifies the entity key of the record that you want to retrieve. | You can select to specify the output of a predecessor node in this section. Must not be the entity key of the current entity. A value is required. |
Family ID list | Specifies the family that the Query Entity node represents. | The Family ID field contains all the APM entity families for which you have the view permission. A value is required. |
Example: Query Entity Node
The following example illustrates how you can use the Query Entity node in the relationship After Insert family policy to retrieve information about the predecessor record. When two records are linked using the relationship, information is copied from the predecessor record to the successor record. A Query Entity node is used to retrieve the data required from fields on the predecessor record, and an Edit Entity node is used to write the data to the successor record.
State Information Nodes in Family Policies
- Before Commit State ID
- Before Commit State Set By User Key
- Before Commit State Set Date and Time
- After Commit State ID
- After Commit State Assigned User Key
- Requested Operation ID
Node Properties
Other than optionally specifying a name for the node, there are no properties to configure for a State Information node.