--- title: Resource Maintenance alias: business-intelligence-cubes-resource-maintenance docsync: true description: "This documentation describes the Resource Maintenance Cube, a ClickHouse data model for tracking maintenance activities across enterprises, sites, and resources" --- # Resource Maintenance Cube ## ClickHouse Cube * cube_resource_maintenance ## Dimensions The **Resource Maintenance** Cube has the following dimensions: | Field | Description | Primary Key | Public | | --- | ----- | - | - | | **Enterprise Name** | The name of the enterprise where the maintenance occurs. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Site Name** | The name of the specific site where the maintenance occurs. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Facility Name** | The name of the facility within the site where the maintenance takes place. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Area Name** | The name of the area within the facility where the maintenance is performed. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Resource Name** | The name of the resource being maintained (e.g., machine or equipment). |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order Name** | The identifier for the specific maintenance order. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order Class** | The classification of the maintenance order (e.g., corrective, preventive). |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order Scheduled Date** | The scheduled date of the maintenance order. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order Schedule State** | The schedule state of the maintenance order (BeforeEarlyDue, EarlyDue, Due, LateDue). |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Name** | The name of the calendar used to schedule the maintenance. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Day FY** | The calendar fiscal year during which the maintenance is scheduled. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Day FQ** | The calendar fiscal quarter during which the maintenance is scheduled. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Day FM** | The calendar fiscal month during which the maintenance is scheduled. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Day FW** | The calendar fiscal week during which the maintenance is scheduled. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Day** | The calendar day during which the maintenance is scheduled. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Timezone** | The timezone associated with the calendar. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Shift** | The work shift during which the maintenance is scheduled. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Shift Name** | The name of the specific work shift during which the maintenance is scheduled. |:material-check:{ style="color: #4DB6AC" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Shift Start** | The start time of the work shift. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Calendar Shift End** | The end time of the work shift. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order Start Date** | The date and time when the maintenance order started. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order End Date** | The date and time when the maintenance order ended. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Maintenance Order Requested On** | The date and time when the maintenance order was requested. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Resource Model** | The model of the resource being maintained. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | | **Resource Resource Type** | The resource type of the resource being maintained. |:material-close:{ style="color: #EF5350" } |:material-check:{ style="color: #4DB6AC" } | Table: Resource Maintenance Dimensions ## Measures The **Resource Maintenance** Cube has the following measures: | Field | Description | Primary Key | Public | Type | Formula | | ---- | ------------ | - | - | - | ---- | | **Record Count** | Total number of maintenance records in the dataset. |:material-close:{ style="color: #EF5350" } | :material-check:{ style="color: #4DB6AC" } | count | | | **Assist Time** | Time the maintenance order is waiting for acknowledgment in the period for unplanned maintenance orders. |:material-close:{ style="color: #EF5350" } | :material-close:{ style="color: #EF5350" } | number | `dateDiff('second', Acknowledge_Time, Begin_Repair_Time)` | | **Repair Time** | Time from the start to the completion of the maintenance order in the period for unplanned maintenance orders. |:material-close:{ style="color: #EF5350" } | :material-close:{ style="color: #EF5350" } | number | `date_diff('second', MaintenanceOrder_StartDate, MaintenanceOrder_EndDate)` | | **MTTA in Seconds** | The average time the maintenance order is waiting for acknowledgment. |:material-close:{ style="color: #EF5350" } | :material-check:{ style="color: #4DB6AC" } | avg | `{assist_time}` | | **MTTRep in Seconds** | The average time taken for repairs in unplanned maintenance orders. |:material-close:{ style="color: #EF5350" } | :material-check:{ style="color: #4DB6AC" } | avg | `{repair_time}` | | **Calendar in UTC** | Calendar Day in UTC |:material-close:{ style="color: #EF5350" } | :material-check:{ style="color: #4DB6AC" } | string | `max(formatDateTime(addMinutes(Calendar_CD, Calendar_TZToUTCInMin), '%Y-%m-%dT%H:%i:%s.000Z'))` | Table: Resource Maintenance Measures !!! warning "Public Keys" All dimensions or measures with the "Public" column marked with a :material-close:{ style="color: #EF5350" } icon must not be used. These are private dimensions/measures, used for intermediate calculations before the aggregations are performed. Using them will result in a query failure.