Skip to main content
InSource KnowledgeCenter

TN Hist309 Querying Historical Alarms and Events from your History Blocks

Description

 

This article from InSource shows how to query Alarms and Events from your History Blocks via the Microsoft SQL Server Management Studio.

  • Author: Glenn Yancey
  • Published: 12/15/2019
  • Applies to: Historian Server 2017 and higher (System Platform Only)

Details

If you are storing your alarms and events in History Blocks, you no longer have the A2ALMDB to query.   In fact, many of the same VIEWS that were part of the A2ALMDB or even the much older WWALMDB are now located in the Runtime DB for your Historian.  Only Galaxy based alarms can be stored in History Blocks (as of Update 3 SP1).  To query, you can reference the following VIEW.   

TN_DEC2019_01.PNG

Keep in mind that when you chose to SELECT the Top 1000 records that the query will give you an error message "Event History no longer supports queries that do not provide time".  We must reference a WHERE clause that focuses on the Timestamp which is denoted by the EventStampUTC field.   Make sure that you reference the EventStampUTC field with a properly formatted datetime in order for the query to execute properly. 

TN_DEC2019_02.PNG