Tenant Override Report

It is often times necessary to generate reports on historical data, which can be equally as important as reporting on real time data. Histories in the station may be configured to record information at specified intervals, a change of value or state, or only when certain other conditions exist. There are also standard logs in the station like the audit log and log history which record operator actions and system errors.

If a tenant has access to override set points or scheduled periods of operation, then it may be a requirement to document these actions. The standard audit log can be used to track the actions, or additional histories could be configured to track the actions as well.

  • Using the Audit Log

    The audit log can be searched for records where a specific set point or component has been overridden. The audit log record displays the timestamp, operation (added, removed, invoked, changed, etc), target (path to component), slot name, old value (occupied, unoccupied, 78 deg F, etc), value (the new value), and the user who performed the operation.

    The bql query builder (see 6-13) can be used to create the query or you can simply type the syntax below.

    history:/demo/AuditHistory|bql:select *
    Figure 45.   Bql query builder creating query for the audit log
    Image
  • Filtering by Operation

    This basic query returns a list of every record in the audit log and every available data column. Since the objective is to only display records relating to an overridden point, the query can be modified as below (see 6-14) to limit the return based on the operation

    history:/demo/AuditHistory|bql:select * where operation like 'Invoked'
    Figure 46.   Figure 14: bql query builder creating query for the audit log filtered by operation
    Image
  • Filtering by Target Component

    The modified query only returns records where the operation is 'invoked'; however, the return is for every component in the station. The query can be further modified as below to limit the return based on the (target) component. (see 6-15)

    history:/demo/AuditHistory|bql:select * where operation like 'Invoked' and target 
    like '/Schedule/Suite100AfterHours'
    Figure 47.   Bql query builder creating query for the audit log filtered by operation and target
    Image
  • Configuring the Displayed Columns

    The return could be cleaned up by further modifying the query as below (see 6-16) to limit the displayed columns.

    history:/demo/AuditHistory|bql:select timestamp as 'Timestamp',value as 'Override Value',
    userName as 'User Name' where operation like 'Invoked' and target like 
    '/Schedule/Suite100AfterHours'
    Figure 48.   Creating query for the audit log filtered by operation, target and columns
    Image
  • Filtering by Specific Actions

    The return is now limited to actions which have been invoked on a specific component in the station by any operator. It may be necessary to further filter the results to a single operator or a specific action. The bql query can be modified as below (see 6-17) to limit the return to the specific operation of operator override to the active state.

    history:/demo/AuditHistory|bql:select timestamp as 'Timestamp',value as 'Override Value',
    userName as 'User Name' where operation like 'Invoked' and target like 
    '/Schedule/Suite100AfterHours' and slotName like 'active'
    Figure 49.   Creating query for the audit log filtered by operation, target, columns and slot
    Image
  • Filtering by Timestamps

    The bql query now produces a fairly presentable table which displays the timestamp, value and operator for each record. The return contains records from any time period in the audit log. Depending on how many records are maintained in the audit log, this could be a fairly large list. It is likely that the query will need to be modified as below to limit the return based on desired date ranges.

    history:/demo/AuditHistory?period=lastMonth|bql:select timestamp as 'Timestamp',value as 
    'Override Value',userName as 'User Name' where operation like 'Invoked' and target like 
    '/Schedule/Suite100AfterHours'
     NOTE: The bql query builder does not support the '?period=' syntax, although it is a valid query. It is necessary to delete this syntax from the query prior to opening the bql query builder.