We will further explain how the Target element is setup.
Rules are assigned to a particular data item in a CRF, via the Target element. The Target must be a valid Item OID, and can be a full or relative OID path. The full OID path would include Event Definition, optional ordinal, CRF, CRF Version, Group, optional ordinal, and Item. A relative path can also be specified by providing only part of the path, normally just the Item OID. Each RuleAssignment may have multiple RuleRefs.
<Target Context=”OC_RULES_V1″>SED_OID[ALL].CRF_OID.GROUP_OID[ALL].ITEM_OID</Target> |
As mentioned above the Target element will specify which item the rules will be evaluated against. Although your expression may be evaluating multiple variables, you must specify one variable on which the error message will appear and the action will occur for. Every one of the OIDs must be in upper case. To specify the exact item we need to provide the following information.
- SED_OID[ALL] We need to tell OpenClinica which Study Event definition the Item were after is going to be. We can also specify an ordinal if this happens to be a repeating event, this could be set to ALL or an integer. If you set it to ALL then all event repeats will evaluated. If you specify a specific integer then only that specific event will be evaluated.
- CRF_OID We specified which Event Definition this item is in, now we need to specify which CRF or CRF Version this item is in. Specifying a CRF Version OID will allow the rules to be evaluated against only that specific version. Whereas specifying a CRF OID will allow evaluating against all CRF versions.
- GROUP_OID[ALL] We specified the Study Event Definition and the CRF where the item is, now we need to specify the Group this item is in. This is important because a group might be a repeating or a non-repeating one. If it is a repeating Group OpenClinica allows you to specify if you want the rule to be evaluated against all of the repeats for the variable or a specific ro one of the repeats (a specific row in the repeating group-table) by setting the ordinal to ALL or an integer.
- ITEM_OID Finally we specify which item this rule will be evaluated against. If you have specified a DiscrepancyNoteAction or EmailAction, this is the also the variable that will be specified in the Discrepancy Note or the Email.
As you see we identify the entities by using their OIDs (unique identifiers ). You can deduce from the example above that OpenClinica defines its own syntax to create these statements. The separator used throughout all these statements is the .