hi,
I am trying to create a alert via sql query for a trap that is received only once when a fault occurs.
below is what I have done and it seems to work but it resets automatically without the fault being fixed yet the trap for "alertPowerSupplyNormal" hasn't come through.
there is only one trap received if the PSU has been pulled out, and one trap received when PSU is online again.
Trigger condition is :-
SELECT Nodes.NodeID, Nodes.Caption FROM Nodes,
(SELECT NodeID AS NodeID, MAX(DateTime) AS DateTime FROM Traps
WHERE Traps.TrapType LIKE '%alertPowerSupplyFailure'
AND NodeID=XX
GROUP BY NodeID ) TrapsTemp
where TrapsTemp.NodeID = Nodes.NodeID
AND TrapsTemp.DateTime > DATEADD(MINUTE, -1,GETDATE())
reset condition is
SELECT Nodes.NodeID, Nodes.Caption FROM Nodes,
(SELECT NodeID AS NodeID, MAX(DateTime) AS DateTime FROM Traps
WHERE Traps.TrapType LIKE '%alertPowerSupplyNormal'
AND NodeID=xx
GROUP BY NodeID ) TrapsTemp
where TrapsTemp.NodeID = Nodes.NodeID
AND TrapsTemp.DateTime > DATEADD(MINUTE, -1,GETDATE())
any idea as to why its reset byitself when the reset condition hasn't been triggered?
regards