The Value Range Validation rule ensures that values in a specified column fall within defined ranges (inclusive of boundary values).
This rule is commonly used to:
- Validate numeric values against acceptable business ranges
- Verify dates fall within expected time periods
Example Usage:
- Check if all employee salaries are between $40,000 and $80,000
- Verify that hire dates fall within the current fiscal year
Configuration Fields
Rule-Specific Configuration
Field Name | Description | Required | Data Type |
---|
Start Value/Date | Minimum allowed value (inclusive) | Yes | Number / Date |
End Value/Date | Maximum allowed value (inclusive) | Yes | Number / Date |
Success Criteria Configuration
This section defines how the rule’s outcome is measured against expected thresholds.
Field Name | Description | Required | Options / Format |
---|
Operator | Comparison operation for result count | Yes | GreaterThan , LessThan , EqualTo , Between |
Threshold Value | Value for comparison (single value for most operators) | Conditional | Number |
Threshold Min | Minimum value (for Between operator) | Conditional | Number |
Threshold Max | Maximum value (for Between operator) | Conditional | Number |
Is Percentage | Whether the threshold represents a percentage of total rows | No | true / false (default: false ) |
Allow Nulls | Whether null values should be treated as valid | No | true / false (default: false ) |
Check For Match | When false , validates for negation of the condition | No | true / false (default: true ) |
employee_id | age | hire_date | salary |
---|
1 | 25 | 2023-01-15 | 45000 |
2 | 32 | 2020-05-22 | 68000 |
3 | 17 | 2024-03-10 | 32000 |
4 | 28 | 2022-11-05 | 52000 |
5 | null | 2024-02-18 | null |
6 | 45 | 2019-08-14 | 75000 |
7 | 52 | 2018-04-30 | 82000 |
Sample Configurations
Example 1: Numeric Range Check
Configuration Field | Value |
---|
Column | salary |
Start Value | 40000 |
End Value | 80000 |
Operator | GreaterThan |
Threshold Value | 5 |
Is Percentage | false |
Allow Nulls | false |
Check For Match | true |
Explanation:
Validates that at least 5 salary values fall between $40,000 and $80,000.
Example 2: Date Range Check
Configuration Field | Value |
---|
Column | hire_date |
Start Date | 2023-01-01 |
End Date | 2024-12-31 |
Operator | Between |
Threshold Min | 4 |
Threshold Max | 6 |
Is Percentage | false |
Allow Nulls | false |
Check For Match | true |
Explanation:
Validates that 4–6 hire dates fall within January 1, 2023 to December 31, 2024.
Sample Output
Column Name | Rule Name | Success Count | Failure Count | Null Count | Within Threshold |
---|
salary | Value Range Validation | 4 | 2 | 1 | No |
hire_date | Value Range Validation | 3 | 3 | 1 | Yes |