Mark Weekend Dates

Start with four pinned ISO date strings. The original order_date column stays unchanged. Read the weekday for each date, then add is_weekend beside it. This flag is useful for grouping or filtering later, but it does not replace the original date.

Adding an exact true/false feature that marks whether a pinned date string falls on Saturday or Sunday.

highlighted = computed this step

Input date strings

Start with 4 pinned ISO date strings.

date strings\text{date strings}
Input Date Stringsroworder_dateA2026-01-02B2026-01-03C2026-01-04D2026-01-05

Exact weekend rule

Mark Saturday and Sunday as true; mark weekdays as false.

weekend rule\text{weekend rule}
Weekend Flag Ruledate isnew featureSaturday or Sundayis_weekend = trueMonday through Fridayis_weekend = false

Add is_weekend

Add is_weekend beside the original date string.

date plus weekend flag\text{date plus weekend flag}
Date with Weekend Flagroworder_dateweekdayis_weekendA2026-01-02FridayfalseB2026-01-03SaturdaytrueC2026-01-04SundaytrueD2026-01-05Mondayfalse