Format of the alarm history
The location and format of the alarm history depends on whether History Format is set to Proprietary or Database. This section describes both.
When the History Format is Proprietary (default), the alarm history is saved as a series of text files in your project’s Alarm folder, with one file per calendar day. The name of each file is ALyymmdd.ALH, where:
- yy is the last two digits of the year in which the alarm history file was generated;
- mm is the month in which the alarm history file was generated; and
- dd is the day of the month on which the alarm history file was generated.
Therefore, the alarm history file for 07 May 2003 is located at […]DocumentsInduSoft Web Studio v7.1 ProjectsprojectnameAlarmAL030507.ALH.
Tip: To change where your project saves these files, use the SetAppAlarmPath function.
Within a specific day’s *.ALH file, each alarm is saved as a new line, using the pipe character ( | ) to delimit the 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|P22|P23 P1|P2|P3|P4|P5|P6|P7|P8|P9|P10|P11|P12|P13|P14|P15|P16|P17|P18|P19|P20|P21|P22|P23 . . P1|P2|P3|P4|P5|P6|P7|P8|P9|P10|P11|P12|P13|P14|P15|P16|P17|P18|P19|P20|P21|P22|P23
When the History Format is Database, the alarm history is saved as a table in whichever database you configured for Alarm Database. For more information, see Saving your alarm history to an external database.
The fields/columns of the alarm history are described below:
Proprietary | Database | Description | File Vers. | |
---|---|---|---|---|
Field Number | Column Name | Data Type | ||
P1 | — | — | File version (Current = 005) | 001 |
P2 | Al_Start_Time | TimeStamp | Start Date (MM/DD/YYYY) | 001 |
P3 | Start Time (HH:MM:SS.mmm) | 001 | ||
P4 | Al_Tag | String | Tag Name | 001 |
P5 | Al_Message | String | Alarm Message | 001 |
P6 | Al_Ack | Boolean | Ack, where:
| 001 |
P7 | Al_Active | Boolean | Active, where:
| 001 |
P8 | Al_Tag_Value | Real | Tag Value when the alarm occurred | 001 |
P9 | Al_Group | Integer | Alarm Group Number | 001 |
P10 | Al_Priority | Integer | Priority Number | 001 |
P11 | Al_Selection | String | Selection | 001 |
P12 | Al_Type | Integer | Type, where:
| 001 |
P13 | Al_Ack_Req | Boolean | Ack required, where:
| 001 |
P14 | Al_Norm_Time | TimeStamp | Normalization Date (MM/DD/YYYY) | 001 |
P15 | Normalization Time (HH:MM:SS.mmm) | 001 | ||
P16 | Al_Ack_Time | TimeStamp | Ack Date (MM/DD/YYYY) | 001 |
P17 | Ack Time (HH:MM:SS.mmm) | 001 | ||
P18 | Al_User | String | User Name | 002 |
P19 | Al_User_Comment | String | Comment | 002 |
P20 | Al_User_Full | String | User Full Name | 003 |
P21 | Al_Station | String | Station | 003 |
P22 | Al_Prev_Tag_Value | Real | Previous Value | 003 |
P23 | Bias | Integer | Time Zone Bias | 003 |
— | Al_Start_Time_ms | Integer | 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 | Integer | 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 | Integer | 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 | Boolean | Deleted, where:
| 003 |
— | Last_Update | TimeStamp | Timestamp of the last update for this alarm. | 003 |
— | Last_Update_ms | Integer | Number of milliseconds for the Last_Update timestamp. This field is used when the database does not support ms in a TimeStamp field. | 003 |
Tip: You can customize the names of the columns in the database table by manually editing the project file (e.g., […]DocumentsInduSoft Web Studio v7.1 Projectsprojectnameprojectname.APP) as follows:
[Alarm] DefaultName=NewName
For example:
[Alarm] Message=Alarm_Message Ack=Acknowledgment