5.2 Data Validation Criteria & Custom Formula Rules

Key Takeaways

  • Excel Data Validation enforces cell entry constraints across eight distinct criteria types, including Whole number, Decimal, List, Date, Time, Text length, Any value, and Custom.
  • List validation can be populated via comma-delimited inline literals or range references; dynamic cascading dropdowns utilize the INDIRECT function to reference named ranges matching prior selections.
  • Custom validation formulas must evaluate to a logical TRUE or FALSE; formulas must use relative referencing for the active input cell and absolute referencing for fixed lookup arrays or threshold ranges.
  • Data Validation is client-side and input-focused; pasting data via the clipboard (Ctrl+V) overwrites cell formatting and bypasses validation rules entirely unless audited retroactively.
Last updated: September 2026

5.2 Data Validation Criteria & Custom Formula Rules

Data integrity is fundamental to institutional spreadsheet design. Without input governance, user errors such as typos, out-of-range dates, negative inventory counts, or duplicated transaction IDs propagate through downstream formulas, destabilizing financial models and reporting dashboards. Excel's Data Validation engine provides automated input verification, constraining data entry at the point of ingestion.

To configure Data Validation, navigate to the Data tab on the ribbon, locate the Data Tools group, and click Data Validation (or use the keyboard sequence Alt + A + V + V). The dialog organizes controls across three tabs: Settings, Input Message, and Error Alert.


Core Validation Criteria Types & Comparison Operators

The Settings tab defines the validation parameters. By default, every cell in a worksheet is set to Any value, meaning no validation occurs. Opening the Allow dropdown reveals seven restrictive criteria types:

Validation CriteriaAllowed Input DataCommon Business Applications
Whole numberInteger values without decimal fractionsHeadcount, inventory counts, product quantities
DecimalContinuous numeric values including fractional decimalsHourly wages, interest rates, financial percentages
ListRestricted items chosen from an inline list or rangeDepartment codes, country names, project statuses
DateValid calendar dates between defined thresholdsFiscal year transactions, project milestones
TimeValid timestamps between defined intervalsEmployee shifts, delivery windows
Text lengthString character counts within specific lengthsFixed-length account IDs, postal codes, state abbreviations
CustomFormula-driven boolean expressions returning TRUE/FALSEUnique IDs, conditional rules, non-standard text masks

When selecting Whole number, Decimal, Date, Time, or Text length, Excel enables the Data operator dropdown, offering relational operators: between, not between, equal to, not equal to, greater than, less than, greater than or equal to, and less than or equal to. For dynamic boundaries, the Minimum and Maximum input boxes can reference cell addresses (e.g., =$G$2) or formulas (e.g., =TODAY()).

Two checkboxes on the Settings tab govern behavior:

  • Ignore blank: When checked, blank or null cells pass validation without triggering error alerts. Unchecking this option enforces mandatory data entry if a dependent formula evaluates blanks.
  • In-cell dropdown: Available exclusively under the List criterion; controls whether a clickable down-arrow glyph appears beside the active cell.

Configuring List Validation & Cascading Dropdowns

The List criterion is Excel's most widely implemented validation rule. List sources can be populated using three distinct techniques:

  1. Inline Literals: Enter comma-separated values directly into the Source input box: North,South,East,West Do not enclose items in quotation marks. Note that any space after a comma becomes part of the list item text.
  2. Worksheet Range References: Reference contiguous cells containing valid entries: =$E$2:$E$10 Always use absolute references ($) so the target list does not shift when validation is copied across rows.
  3. Defined Named Ranges: Assign a descriptive name to a range and reference it with an equals sign: =RegionList

Cascading (Dependent) Dropdown Lists

Enterprise forms often require secondary dropdowns to update dynamically based on a primary selection (e.g., selecting a Region in cell A2 restricts cell B2 to departments within that region).

To build cascading lists:

  1. Create named ranges whose defined names match the exact items in the primary list (e.g., named ranges North, South, East, West).
  2. Set the primary cell's validation to =RegionList.
  3. In secondary cell B2, set Data Validation to List and enter the INDIRECT formula: =INDIRECT($A2) The INDIRECT function converts the text string selected in cell A2 into an active range reference, dynamically loading the corresponding subcategory items into B2.

Custom Formula Validation: Logic & Reference Anchoring

When pre-configured numeric or list rules cannot satisfy complex business requirements, the Custom option empowers analysts to author formula-driven rules.

The Governing Rules of Custom Validation Formulas:

  • The formula must evaluate to a logical boolean: TRUE permits the entry, while FALSE rejects the entry.
  • If a custom formula generates an error (#N/A, #VALUE!, #REF!), Excel treats the result as FALSE and blocks the input.
  • The Active Cell Rule: When applying a validation rule to a multi-cell selection (e.g., A2:A100), write the formula relative to the active cell (the white cell in the selection, typically the top-left cell A2). Excel automatically transposes relative row and column coordinates for every other cell in the range.
Common Custom Validation Formulas:
┌──────────────────────────────────────┬────────────────────────────────────────────────────────┐
│ Business Requirement                 │ Validation Formula (Applied to Range starting at A2)   │
├──────────────────────────────────────┼────────────────────────────────────────────────────────┤
│ Prevent Duplicate Entries            │ =COUNTIF($A$2:$A$100, A2)<=1                           │
│ Restrict Input to Numbers Only       │ =ISNUMBER(A2)                                          │
│ Restrict Input to Text Characters    │ =ISTEXT(A2)                                            │
│ Enforce Future Dates Only            │ =A2>=TODAY()                                           │
│ Enforce Uppercase Text Only          │ =EXACT(A2, UPPER(A2))                                  │
│ Prohibit Leading/Trailing Spaces     │ =A2=TRIM(A2)                                           │
│ Require Valid Email Domain           │ =AND(ISNUMBER(FIND("@", A2)), ISNUMBER(FIND(".", A2))) │
└──────────────────────────────────────┴────────────────────────────────────────────────────────┘

Exam Pitfall: In =COUNTIF($A$2:$A$100, A2)<=1, failing to lock the range with dollar signs ($A$2:$A$100) causes the comparison range to drift downward as rows advance. By row 10, Excel would check A10:A108, allowing earlier duplicates to slip through undetected.


Clipboard Bypass Vectors & Validation Limitations

Data Validation intercepts keyboard entry and direct cell edits, but candidates must recognize its structural vulnerabilities:

  • Clipboard Paste (Ctrl+V): Pasting data from an external source or unvalidated cell overwrites both the cell content and its underlying Data Validation settings. The validation rule is eradicated, and invalid data enters undetected.
  • Fill Handle & Drag-and-Drop: Dragging a cell across validated cells can copy source formatting and overwrite validation rules unless the fill option is explicitly set to "Fill Without Formatting".
  • The "Ignore blank" Nuance: If "Ignore blank" is enabled and a custom validation formula references an empty cell, Excel may bypass formula evaluation entirely, treating the empty cell as inherently valid.
Test Your Knowledge

An inventory clerk needs to ensure that serialized asset tags entered into range A2:A200 are strictly unique. With cell A2 selected as the active cell, which Data Validation custom formula must be applied?

A
B
C
D
Test Your Knowledge

What occurs when a user copies data from an external source or unvalidated cell and pastes it (Ctrl+V) into a worksheet range governed by Data Validation?

A
B
C
D
Test Your Knowledge

A project budget template requires cell B2 to display a dropdown list of subcategories based on the department name chosen in cell A2. If each department name corresponds to an identically named range in the workbook, what formula must be entered into the List Source box for cell B2?

A
B
C
D