Alarm History Database

The alarm history can be saved either in the IWS proprietary format or to an external SQL Relational database by ADO. The alarm history settings can be configured in the project settings (Options on the Project tab of the ribbon):
Figure 1. Project Settings: Options tab

The Alarm History and Events interface allows you to configure the following settings:
Field Remarks Syntax
History Life Time (days) The history for alarm/event messages older than the number of days specified in this field are automatically deleted, following a FIFO (First-In, First-Out) behavior. If this field is left in blank, the history of alarms/events are not deleted automatically. Number
History Format Defines the format of the history of alarms/events:
  • Proprietary: Saves the history in the proprietary format. The alarm messages are saved in a text file with the name ALyymmdd.ALH, where:
    • yy is the last two digits of the current year.
    • mm is the month.
    • dd is the day

    There will be one history file for each day. By default, the alarm history files created with the proprietary format are stored in the \Alarm sub-folder of the project. However, it is possible to direct the alarms to a different directory by using the SetAppAlarmPath function from the built-in language.

  • Database: Saves the history in a third-party SQL Relational Database (e.g., SQL Server).
Combo-box
Alarm Database When selecting Database as the format for the history of alarms, the specific settings to interface with the third-party SQL Relational Database can be configured by the dialog launched when pressing this button. For further details about support for third-party SQL Relational Databases, see Database Interface.
When saving the alarm history in the proprietary format, each alarm event is saved in a new line, using the pipe character ( | ) to delimiter the different fields, as illustrated below:
P1|P2|P3|P4|P5|P6|P7|P8|P9|P10|P11|P12|P13|P14|P15|P16|P17|P18|P19|P20|P21
P1|P2|P3|P4|P5|P6|P7|P8|P9|P10|P11|P12|P13|P14|P15|P16|P17|P18|P19|P20|P21
.
.
P1|P2|P3|P4|P5|P6|P7|P8|P9|P10|P11|P12|P13|P14|P15|P16|P17|P18|P19|P20|P21
The format of the history both in proprietary format and in the SQL Relational Database format is described in the following table:
Proprietary SQL Relational Database Remarks File Vers.
Field No. Field Name Field Type
P1 File version (Current = 003) 001
P2 Al_Start_Time Date/Time Start Date (DD/MM/YYYY) 001
P3 Start Time (HH:MM:SS) 001
P4 Al_Tag Text Tag Name 001
P5 Al_Message Text Alarm Message 001
P6 Al_Ack Number Ack, where:
  • 0: Alarm was acknowledged or does not require acknowledgment
  • 1: Alarm was not acknowledged
001
P7 Al_Active Number Active, where:
  • 0: Alarm is not active
  • 1: Alarm is active
001
P8 Al_Tag_Value Number Tag Value when the event occurred 001
P9 Al_Group Number Alarm Group Number 001
P10 Al_Priority Number Priority Number 001
P11 Al_Selection Text Selection 001
P12 Al_Type Number Type, where:
  • 1 is HiHi
  • 2 is Hi(On)
  • 4 is Lo(Off)
  • 8 is LoLo
  • 16 is Rate(Change)
  • 32 is Deviation+
  • 64 is Deviation-
001
P13 Al_Ack_Req Number Ack required, where:
  • 0: Alarm requires acknowledge
  • 1: Alarm does not require acknowldge
001
P14 Al_Norm_Time Date/Time Normalization Date (DD/MM/YYYY) 001
P15 Normalization Time (HH:MM:SS) 001
P16 Al_Ack_Time Date/Time Ack Date (DD/MM/YYYY) 001
P17 Ack Time (HH:MM:SS) 001
P18 Al_User   User Name 002
P19 Al_User_Comment   Comment 002
P20 Al_User_Full   User Full Name 003
P21 Al_Station   Station 003
P22 Al_Prev_Tag_Value Number Previous Value 003
P23 Bias Number Time Zone Bias 003
Al_Start_Time_ms Number Number of milliseconds for the Start Time timestamp. This field is used when the database does not support ms in a TimeStamp field. 003
Al_Norm_Time_ms Number Number of milliseconds for the Norm Time timestamp. This field is used when the database does not support ms in a TimeStamp field. 003
Al_Ack_Time_ms Number Number of milliseconds for the Ack Time timestamp. This field is used when the database does not support ms in a TimeStamp field. 003
Al_Deleted Number Deleted, where:
  • 0: Alarm message was not deleted by the user (not visible).
  • 1: Alarm message was deleted by the user (visible).
003
Last_Update Date/Time Timestamp of the last update for this event. 003
Last_Update_ms Number Number of milliseconds for the Last Event timestamp. This field is used when the database does not support ms in a TimeStamp field. 003
See also:
Гидроизоляция мапей поиск продуктов для гидроизоляция.