About validation rules

With a validation rule, you define the specific criteria that must be met for the answer to a question to be considered correct or acceptable. Validation rules can be configured as simple validations, which throw an error message, to raise queries, or both.

When you add a validation rule, you have two configuration toggles available: Validation and Create a Query.

For each validation rule, you must activate at least one toggle, but you can activate them both. Depending on the configuration the result can be different. Consult the table below to learn more about the behavior of validation rules.

Note:

If you try to deactivate the second toggle, the first one is enabled automatically.
Type of rule Configuration Behavior
Validation only
  • Validation: On
  • Create a Query: Off

The system throws errors and prevents site users from performing Randomization and Trial Supply Management (RTSM) actions until those errors are resolved. To address the errors, update the question with a value that satisfies the validation criteria.

Invalid answers are displayed with a red outline and an error message, which you specify when configuring the rule.

Query only
  • Validation: Off
  • Create a Query: On

The system raises a query on answers that don't meet the given criteria to identify them for data reviewers, but without impacting RTSM actions. Site users can answer these queries to follow the normal query workflow, and they can also be closed directly by a sponsor user, or by updating the data.

Queries only display once data is saved and submitted. However, when entering data, a red outline and an error message appear (as in validation) to warn the site user of failed criteria, allowing them to correct the answer before saving, if applicable. If data is submitted and the query raises, given that the rule doesn't include validation functionality, the failed validation indicators disappear.

Validation raised as a query
  • Validation: On
  • Create a Query: On

The system raises a query on the invalid answers at the time it throws errors and prevents RTSM actions. Site users can update the answer to resolve errors, but sponsor users can also close the related queries to allow the impacted RTSM actions to proceed, without first being required to address the validation error.

When entering data that doesn't meet the validation criteria, a red outline and an error message display upon data entry. A query is then raised, but only once data is submitted. Since this rule includes both validation and query functionality, the answer becomes invalid and the failed validation indicators do not disappear.

The RTSM actions that can be impacted by validation rules are screening, randomization and dispensation. Whether a specific RTSM action is impacted or not, depends on the question's settings and whether it is required for those events. Invalid answers provided for questions that are required for randomization or dispensation prevent those actions for the given subject. In the case of a question required for screening, an invalid answer results in automatic screen fail. See Specify Randomization and Trial Supply Management (RTSM) actions that require complete answers.

About multiple validations

Depending on the type of question you are working with, different predefined options for validation rules are available. If applicable, you can define more than one validation rule for a question, but only for question types that have more than one validation rule option. These question types are:
  • Date/Time
  • Date of birth
  • Number
  • Age
  • Drop-down
  • Checkbox

For more information on the validation rules available for each question type see Available validation rules by question type.

When you apply multiple validations to a question you must select a logical operator. See the table below for the available logical operators:

Note:

These operators cannot be combined if more than two validation rules are configured. For example, if you have three validation rules on a question, you can select AND for every rule instance or OR for every rule instance, but you cannot select AND followed by OR.
Logical operator Definition Processing
AND

The value must be valid for every validation rule.

All validation rules are processed and an error message or query displays for every failed condition. All errors must be resolved in order for the AND condition to be met and the answer to become valid.

OR

The value must be valid for at least one validation rule.

The validation rules are processed until one condition is met or until all have been evaluated and failed. If all validations are failed, all error messages or queries display separately. If at least one of those conditions is resolved, the OR condition is met and the answer becomes valid with all queries or error messages cleared.

For further details about how to set validation rules for a specific question type, browse other topics in this section.