Logical
Audit uppercase-style codes and Monday–Friday dates with EXACT and WEEKDAY
Check that a code is nonblank text unchanged by UPPER, and that a scheduling date is an integer date in 2026 falling Monday through Friday.
Why A2 = UPPER(A2) fails in spreadsheets—use case-sensitive EXACT!
EXACT performs a case-sensitive comparison between the text and its uppercase conversion. The rule here also requires text and at least one non-space character. It does not define a complete SKU format: punctuation, digits stored as text, and scripts without letter case may pass. Define additional length or allowed-character rules for your own identifiers.
The date rule is deliberately scoped to this 2026 scheduling example: require a numeric whole-day date from January 1 through December 31, then check Monday–Friday. This is not a holiday calendar or a settlement-day rule. Formula results are audit indicators; evaluating them does not itself install an input restriction in the application.
| SKU Code (A) | Scheduled Date (B) | Uppercase Rule | Weekday Rule & Combined |
|---|---|---|---|
| SKU-900 | 2026-10-30 (Fri) | TRUE | Weekday 5 <= 5 -> TRUE (Valid) |
| sku-901 | 2026-10-30 (Fri) | FALSE (lowercase!) | Combined -> FALSE |
| SKU-902 | 2026-10-31 (Sat) | TRUE | Weekday 6 > 5 -> FALSE (Weekend!) |
| 12345 (Number) | 2026-10-29 (Thu) | FALSE (ISTEXT fails) | Rejects bare numbers |
Audit nonblank text unchanged by UPPER
ISTEXT rejects numeric cell values. Text containing only punctuation or digits still passes the uppercase comparison; the rule does not require an alphabetic character.
=AND(ISTEXT(A2),LEN(TRIM(A2))>0,EXACT(A2,UPPER(A2)))Combine code and 2026 weekday checks
The outer IF checks the type before date arithmetic, so non-date text returns FALSE. Whole-day dates outside 2026 and timestamps with a fractional day are rejected. Weekday does not mean a public holiday is excluded.
=IF(ISNUMBER(B2),IF(AND(B2>=DATE(2026,1,1),B2<=DATE(2026,12,31),B2=INT(B2)),AND(AND(ISTEXT(A2),LEN(TRIM(A2))>0,EXACT(A2,UPPER(A2))),WEEKDAY(B2,2)<=5),FALSE),FALSE)Try the example
Use the original values or change them to test your understanding.