Applies To:
  • CitectSCADA 5.50, 6.0, 6.1, 7.0
  • CitectHMI 5.50, 6.0, 6.1, 7.0

Summary:


I am trying to use the AlarmSetQuery function to filter my alarm by categories. 
The function works correctly for the first time. 
However, if I dynamically change the filter criteria (add/remove a category), then alarmsetquery woudl still use the older set of categories.


 


Solution:

The filter function only works the first time, because by default, the alarm server runs filter queries in an optimised fashion.  This
optimisation relies on the query cicode being based purely on alarm data, and
will only re-run the query code if the version of the alarm has changed since last time.


This behaviour can be disabled through the 'iAlways' parameter of the AlarmSetQuery function.
This parameter is not documented in v6.10 help, but it is in v7.0, as follows:

AlarmSetQuery(AN, QueryFunction [, sArgs] [, iAlways] )

iAlways:
Set to TRUE to ensure the query is always done (no optimization). Default value is 0 (FALSE).

 

Keywords:
 

Attachments