Maintenance mode – tying the text of the category to the database
In the OpsDB and DWDB – we keep some tables names MaintenanceMode and MaintenanceModeHistory.
When you place an object into maintenance mode – we will log a row in the database for this object. You could potentially write reports against this data in the data warehouse, and report on MM history.
From the following query:
select * from dbo.vMaintenanceModeHistory
There is a column named “ReasonCode” This has a numeric value. However – in the UI – this correlates to the “Category” that you must select when you place an object into MM:
Here is a table which sorts out the numeric reason code vs the text in the UI: