Skip to main content

SYS.Monitor.Alert

persistent class SYS.Monitor.Alert extends %Library.Persistent

SQL Table Name: SYS_Monitor.Alert

Property Inventory

Properties

property AlertTime as %String [ Required ];
Date/Time of Alert
Property methods: AlertTimeDisplayToLogical(), AlertTimeGet(), AlertTimeGetStored(), AlertTimeIsValid(), AlertTimeLogicalToDisplay(), AlertTimeLogicalToOdbc(), AlertTimeNormalize(), AlertTimeSet()
property Msg as %String (MAXLEN = 250);
Alert message
Property methods: MsgDisplayToLogical(), MsgGet(), MsgGetStored(), MsgIsValid(), MsgLogicalToDisplay(), MsgLogicalToOdbc(), MsgNormalize(), MsgSet()
property PrevState as %Integer [ Required ];
Previous state
Property methods: PrevStateDisplayToLogical(), PrevStateGet(), PrevStateGetStored(), PrevStateIsValid(), PrevStateLogicalToDisplay(), PrevStateNormalize(), PrevStateSet()
property Sensor as %String (MAXLEN = 250);
Name of sensor
Property methods: SensorDisplayToLogical(), SensorGet(), SensorGetStored(), SensorIsValid(), SensorLogicalToDisplay(), SensorLogicalToOdbc(), SensorNormalize(), SensorSet()
property State as %Integer [ Required ];
Current state
Property methods: StateDisplayToLogical(), StateGet(), StateGetStored(), StateIsValid(), StateLogicalToDisplay(), StateNormalize(), StateSet()

Queries

query Alerts(BeginTime As %String, EndTime As %String)
SQL Query:
SELECT * FROM Alert WHERE AlertTime BETWEEN :BeginTime AND :EndTime
Return the alerts for a given date/time range. Date/time is in $zdt($h,3) format.
query AlertsBySensor(BeginTime As %String, EndTime As %String, Sensor As %String)
SQL Query:
SELECT * FROM Alert WHERE AlertTime BETWEEN :BeginTime AND :EndTime AND Sensor = :Sensor
Return the alert(s) for a given sensor, for a given date/time range. Date/time is in $zdt($h,3) format.
query HealthState()
SQL Query:
SELECT * FROM Alert WHERE AlertTime >= (SELECT MAX(AlertTime) FROM Alert WHERE PrevState = 0)
Return the alerts between current state, and previous green state

Indexes

index (IDKEY on ) [IdKey, Type = key];
Index methods: IDKEYCheck(), IDKEYDelete(), IDKEYExists(), IDKEYOpen(), IDKEYSQLCheckUnique(), IDKEYSQLExists(), IDKEYSQLFindPKeyByConstraint(), IDKEYSQLFindRowIDByConstraint()

Inherited Members

Inherited Methods

Storage

Storage Model: CacheStorage (SYS.Monitor.Alert)

^ISC.Monitor.AlertD(ID)
=
%%CLASSNAME
Sensor
Item
Rulecode
Severity
Values
Readings
Mean
Sigma
AlertTime
Value
PrevState
State
AlertTime
FirstAlertTime
Msg
FeedbackOpens in a new tab