Data Persistence and Historical Logging

Data Persistence and Historical Logging

By default, Internal Tags run in the computer’s RAM (Volatile) memory. This means that data will be lost when the computer is turned off or if the power is cut. Wise SCADA offers two different mechanisms to protect your data:

1. Historical Logging

This feature saves the tag’s value to the Database (SQL) along with a timestamp.

  • Purpose: To provide retrospective reporting, trend charts, and process analysis.
  • How It Works: When the “Historical” setting is configured for a tag, values are archived in the database at defined intervals or upon change.
  • Usage: Configured via the Historical Tags page.

2. Data Persistence – “Startup Memory” (Last Value)

This feature ensures that when SCADA is closed and reopened, the tag starts with its last recorded value.

  • Purpose: To maintain system continuity (e.g., preventing a setpoint or a counter from resetting).
  • How It Works (Difference Between Runtime and Development): The system records tag values as they change in Runtime mode and writes these final values to a specific file (“Last Value”) during a proper shutdown. When the program (Runtime or Development) is restarted, the system reads this file first.
  • Important Note: If you manually change tag values in Development mode and save the project, these changes will not overwrite the existing “Last Value” file. Even when you close the project and reopen Development or Runtime, the system will always read the values from the previous “Last Value” record. For the new values defined during the Development phase to take effect (allowing the system to start with these new values), the previously created “Last Value” record must be deleted.
Critical Warning: Risk of Abnormal Shutdown and Data Loss

The Persistence feature works on a “Save on Exit” logic.

  • The Risk: If a sudden power outage occurs, Windows crashes, or the SCADA process is forcibly terminated via “Task Manager,” the closing routine cannot execute. Therefore, the last values cannot be written to the file. The system will open using the data from the last successful save (or the default value).

Solution Recommendations:

  • UPS Usage: Use an Uninterruptible Power Supply (UPS) that keeps the computer running long enough to shut down the program properly.
  • Critical Data: For data where loss cannot be tolerated (such as production totals), it is recommended to use PLC Memory or Database (Historical) records instead of Internal Tags. PLCs are generally not affected by power outages as they have battery-backed memory.

Leave a Reply