Coming Soon - This feature is currently in development and will be available in an upcoming release.

Working Calendar Duration Calculations

Overview

mindzie now supports working calendar-aware duration calculations across filters, calculators, and enrichment operators. When enabled, duration calculations exclude non-working time such as nights, weekends, and holidays - giving you accurate business hour measurements instead of raw calendar time.

How It Works

Standard Calendar Time vs Working Calendar Time

Scenario Calendar Time Working Calendar Time (9-5 Mon-Fri)
Monday 4pm to Tuesday 10am 18 hours 2 hours (1hr Mon + 1hr Tue)
Friday 3pm to Monday 9am 66 hours 2 hours (Fri 3-5pm only)
Activity on a holiday Counted Excluded

The "Use Working Calendar" Option

When a Working Calendar is configured on your event log, a new checkbox appears in duration-related editors:

[x] Use Working Calendar (business hours only)

When enabled, durations exclude nights, weekends, and holidays
defined in the working calendar.

Important: This option only appears when your event log has a Working Calendar configured. If you don't see the option, you need to first add the "Set Working Calendar" enrichment to define your business hours.

Setting Up a Working Calendar

Before you can use working calendar durations, you must configure a Working Calendar on your event log:

  1. Open your notebook/analysis
  2. Add an enrichment block
  3. Select Set Working Calendar operator
  4. Configure your working hours (e.g., 9:00 AM - 5:00 PM)
  5. Configure working days (e.g., Monday - Friday)
  6. Optionally add holidays
  7. Execute the notebook

Once configured, all duration editors will show the "Use Working Calendar" option.

Supported Components

The following components support the Use Working Calendar option:

Filters

Filter Description
Case Duration Filter cases by total duration from first to last event
Time Between Activities Filter cases by duration between two specific activities

Calculators

Calculator Description
Time Between Selected Events Calculate duration statistics between two event types
Time To Activity Calculate duration from case start to a specific activity

Enrichment Operators

Operator Description
Duration Between Activities Create a case attribute with time between two activities
Duration From Attribute To Activity Calculate duration from a date attribute to an activity
Duration From Case Attribute To Activity Times Calculate duration from case attribute to multiple activity occurrences
Time Difference From Activity To Current Time Calculate aging from an activity to current time
Time Difference From Current Time Calculate aging from a date attribute to current time
Event Time Difference Calculate duration between two event-level date/time attributes

Behavior Details

Tri-State Logic

The Use Working Calendar setting uses tri-state logic:

Value Behavior
Unchecked Force calendar time (ignore working calendar even if configured)
Checked Force working calendar (use business hours only)
Default (when not explicitly set) Follow log default setting

Graceful Fallback

If Use Working Calendar is enabled but no calendar is configured on the log, the calculation silently falls back to standard calendar time. This ensures backward compatibility and prevents errors.

Persistence

The Use Working Calendar setting is saved with the filter, calculator, or enrichment operator configuration. When you edit an existing block, the setting will be restored to its previous value.

Use Cases

Measuring True Processing Time

Scenario: You want to measure how long your team takes to process invoices, but raw calendar time includes nights and weekends when no one is working.

Solution:

  1. Configure a 9-5 Mon-Fri working calendar
  2. Use the "Duration Between Activities" enrichment with Use Working Calendar enabled
  3. Durations now reflect actual working time

SLA Compliance Monitoring

Scenario: Your SLA requires responding to customer requests within 4 business hours, not 4 calendar hours.

Solution:

  1. Configure your working calendar with your support hours
  2. Use "Time Difference From Activity To Current Time" with Use Working Calendar enabled
  3. Filter or alert on cases exceeding 4 hours of working time

Accurate Aging Reports

Scenario: You need to report on how long cases have been waiting, but weekends shouldn't count against the aging metric.

Solution:

  1. Configure a working calendar
  2. Use "Time Difference From Current Time" with Use Working Calendar enabled
  3. Aging reflects only business hours

Technical Notes

  • Working calendar calculations use the WorkingCalendarCalculator class centrally
  • All duration calculations route through this calculator when enabled
  • The working calendar is stored on the SuperLog object
  • Calculations support complex calendars with varying hours per day and holiday exceptions