Auto-Flag Double-Booked Workers
in Your Excel Shift Schedule

One formula using IFERROR + COUNTIFS drops directly into your existing roster and turns every double-booking into an instant red flag โ€” before the shift starts, not after the floor is short-staffed.

โฑ15 minutes
๐Ÿ“ŠExcel 2016+
๐ŸญFor plant managers
โœ“Copy-paste ready

Founding-customer offer ยท First buyers only

ShiftIQ Starter Pack โ€” 3 Excel production-scheduling micro-courses

INDEX/MATCH shift rosters ยท Bottleneck tracking ยท Downtime dashboards

Buy Now โ€” $9.50 โ†’

One-time ยท Instant delivery

You manage a 40-person shift roster. Your schedule lives in Excel โ€” dates in column A, shift names in column B (Morning / Afternoon / Night), worker names in column C. It works, mostly. But twice last quarter, someone got scheduled for two shifts in a single day. You caught the first one because a worker called in confused. You didn't catch the second one until 5:45 a.m.

Manually scanning 200 rows for duplicates before every posting cycle is where errors hide. Excel can do this for you โ€” automatically, on every row, the moment you paste in a new name.

A Conflict Alert column (column D) that instantly shows โš  DOUBLE-BOOKED if any worker appears twice on the same date, or โœ“ OK if the row is clean. It requires no macros, no add-ins โ€” just one formula you copy down the column.


01

Set Up Your Schedule Table

Your schedule table needs at minimum three columns. If yours already has them under different names, note the column letters โ€” you'll substitute them in the formula below.

ABCD
DateShiftWorkerConflict Alert
7/14/2026MorningRodriguez, Mโ† formula goes here
7/14/2026AfternoonChen, L
7/14/2026MorningRodriguez, Mโ† duplicate!
7/14/2026NightTorres, J
7/15/2026MorningChen, L
7/15/2026AfternoonRodriguez, M

Row 4 above is the problem row โ€” Rodriguez is already on Morning that day. The formula will flag both row 2 and row 4.

TIP: If your dates are stored as text strings instead of real Excel dates, the COUNTIFS formula will still work โ€” it matches by value, not by date type.
02

Enter the Core COUNTIFS Formula

Click cell D2 and type this formula, then press Enter:

=IF(COUNTIFS($A$2:$A$200, A2, $C$2:$C$200, C2) > 1, "โš  DOUBLE-BOOKED", "โœ“ OK")

How it works โ€” reading left to right:

  • COUNTIFS($A$2:$A$200, A2, โ€ฆ)Count every row where column A equals this row's date. The $ signs lock the range so it doesn't shift when you copy the formula down.
  • โ€ฆ $C$2:$C$200, C2)AND column C equals this row's worker name. COUNTIFS only counts rows where both conditions are true simultaneously.
  • > 1If the count is greater than 1, this worker appears more than once on this date โ€” a conflict.
  • "โš  DOUBLE-BOOKED"The text displayed when a conflict is found. You can change this to any flag you want.
TIP: Why 200 rows? It gives you room to grow without slowing Excel. Change it to 1000 if your roster exceeds 200 lines, but avoid using full-column references like $A:$A on large files โ€” they recalculate every keystroke.
03

Wrap With IFERROR to Handle Empty Rows

If column A or C has any blank cells, the basic formula can return an error instead of silently skipping. Wrap it with IFERROR so blanks display a dash instead:

=IFERROR(
  IF(COUNTIFS($A$2:$A$200, A2, $C$2:$C$200, C2) > 1,
     "โš  DOUBLE-BOOKED",
     "โœ“ OK"),
  "โ€”")

The IFERROR(formula, "โ€”") wrapper catches any formula error and displays โ€” instead. This keeps the column clean even if you have header rows, subtotals, or gaps in your data.

Now copy cell D2 and paste it down through D200 (or however many rows your schedule uses). Every row with a double-booked worker will immediately show โš  DOUBLE-BOOKED.

04

Extend With INDEX/MATCH to Identify Which Shift Conflicts

The basic formula tells you that a conflict exists. This advanced version tells you which other shift the worker is already assigned to โ€” so you can resolve it immediately without scrolling.

=IFERROR(
  IF(COUNTIFS($A$2:$A$200, A2, $C$2:$C$200, C2) > 1,
     "โš  Also on: " & INDEX($B$2:$B$200,
       MATCH(A2 & C2, $A$2:$A$200 & $C$2:$C$200, 0)),
     "โœ“ OK"),
  "โ€”")
โš  IMPORTANT: This is an array formula. After typing it, press Ctrl + Shift + Enter instead of just Enter. Excel will wrap it in { } curly braces. In Excel 365 or Excel 2021+, you can just press Enter normally.

What the INDEX/MATCH addition does:

  • A2 & C2Concatenates the date and worker name into a single lookup key, e.g. '44026Rodriguez, M'. This lets MATCH search for a combined match.
  • $A$2:$A$200 & $C$2:$C$200Builds the same combined key for every row in the range. MATCH finds the first row where both date and name match.
  • INDEX($B$2:$B$200, โ€ฆ)Returns the shift name from column B at the matched row โ€” so you see exactly which shift is the other booking.

With this formula, a flagged row will now show: โš  Also on: Morningโ€” telling you Rodriguez is already on Morning shift that day, and you're about to double-book her on Afternoon.

05

Add Conditional Formatting to Highlight Entire Rows

The formula does the detection. Conditional formatting makes conflicts impossible to miss โ€” the entire row turns red the moment a conflict is flagged.

  1. Select your entire data range โ€” e.g. A2:D200
  2. Go to Home โ†’ Conditional Formatting โ†’ New Rule
  3. Choose "Use a formula to determine which cells to format"
  4. Enter this formula:
    =$D2="โš  DOUBLE-BOOKED"
    The $D2 locks column D but lets the row number change โ€” so every row checks its own D column.
  5. Click Format, choose a red fill, click OK.

Now any row where column D contains the conflict flag will turn red across all four columns โ€” instantly visible even when you're scrolling fast.

Here's what your schedule looks like before and after applying the formula. The conflict rows (2 and 4 โ€” Rodriguez on 7/14) are immediately surfaced.

ABCD
DateShiftWorkerConflict Alert
7/14/2026MorningRodriguez, Mโš  DOUBLE-BOOKED
7/14/2026AfternoonChen, Lโœ“ OK
7/14/2026MorningRodriguez, Mโš  DOUBLE-BOOKED
7/14/2026NightTorres, Jโœ“ OK
7/15/2026MorningChen, Lโœ“ OK
7/15/2026AfternoonRodriguez, Mโœ“ OK

Both rows flagging Rodriguez on 7/14 are now visible without any scrolling or manual scan. You can sort by column D to push all conflicts to the top before posting the schedule.

Basic version (D2, copy down):

=IFERROR(IF(COUNTIFS($A$2:$A$200,A2,$C$2:$C$200,C2)>1,"โš  DOUBLE-BOOKED","โœ“ OK"),"โ€”")

Advanced version (Ctrl+Shift+Enter):

=IFERROR(
  IF(COUNTIFS($A$2:$A$200, A2, $C$2:$C$200, C2) > 1,
     "โš  Also on: " & INDEX($B$2:$B$200,
       MATCH(A2 & C2, $A$2:$A$200 & $C$2:$C$200, 0)),
     "โœ“ OK"),
  "โ€”")

Conditional formatting formula:

=$D2="โš  DOUBLE-BOOKED"

Problem: Formula returns 0 or always shows โœ“ OK even with obvious duplicates

Fix: Your worker names probably have trailing spaces. Add TRIM: change C2 to TRIM(C2) and $C$2:$C$200 โ€” unfortunately COUNTIFS doesn't accept TRIM inside it. Instead, add a helper column E with =TRIM(C2) and run COUNTIFS against that column.

Problem: The array formula doesn't work (returns #VALUE!)

Fix: Make sure you pressed Ctrl+Shift+Enter, not just Enter. In older Excel versions the formula MUST be confirmed as an array formula. In Excel 365 this is automatic.

Problem: Conditional formatting highlights wrong rows

Fix: Check that your formula uses $D2 (column locked, row unlocked) and that you applied it starting from A2, not A1. If your header row is row 1, the formula row reference must start at row 2.

ShiftIQ Starter Pack

3 Excel production-scheduling micro-courses โ€” founding price $9.50 one-time

  • โ†’INDEX/MATCH shift rosters โ€” build dynamic schedules that auto-update
  • โ†’Bottleneck tracking โ€” flag capacity constraints before the shift starts
  • โ†’Downtime dashboards โ€” measure and visualise production losses in Excel
Get the Starter Pack โ€” $9.50 โ†’

Founding-customer price ยท First buyers only

Instant delivery ยท No subscription ยท One-time purchase

ยฉ 2026 ShiftIQ ยท Excel micro-courses for plant managers ยท Back to home