rdbHsqlDb-HsqlDatabase

This component models an HsqlDb (Hyperthreaded Structured Query Language Database) relational database in a remote controller station. The HSQL Development Group maintains the standard for this database, which is available under a BSD type (free) license.

The rdbHsqlDb palette provides the HsqlDbDatabase components.

Figure 1. HsqlDbDatabase properties


You access the properties to configure the driver for this database by expanding Config > Drivers > RdbmsNetwork, and double-clicking the HsqlDbDatabase node in the Nav tree.

In addition to the standard properties (Status, Enabled, Fault Cause, Health and Alarm Source Info), these properties support this component.

PropertyValueDescription
Use Encrypted Connectiontrue or false (default)
Indicates if the connection between the station and the database is secure (true) or not secure (false). To ensure that your system cannot be hacked, leave this property set to true. Change it only if your database does not support data encryption.
User Nametext
Defines the user name used to log in to the database.

Login credentials must provide sufficient database privileges to allow you to perform one or more (depending on database type) of these commands: CREATE TABLE, CREATE INDEX, CREATE SEQUENCE

Passwordtext
Defines the password required to log in to the database. The Confirm property must be an exact match to the Password property.
Workeradditional propertiesThe “rdb-RdbmsWorker” topic documents these properties.
Export Modedrop-down list
Specifies how histories are exported to the specified database.

By History Id exports one table per History Id. This is the default value setting.

By History Type exports one table per History Type. This option may make the data easier to query once exported.

Use Unicode Encoding Schemetrue or false (default)
Creates history table schemas with the Universal character set Transformation Format (UTF-8) or Unicode data types for string-valued columns to store Asian character sets.

false maintains backward compatibility with legacy history export mechanisms.

true enables the NVARCHAR data type for any column in a table that expects string data.
Note: An Update Wizard is available to upgrade existing databases to support Unicode.
Timestamp Storagedrop-down list
Exports or updates history timestamps to Coordinated Universal Time (UTC) enabling the export of history records from different timezones into a common database and be chronologically correct and independent of any specific source timezone characteristics. In other words, exported histories show the timestamp data from where the history is actually stored, making useable histories with a consistent timestamp.

Dialect Default maintains compatibility with legacy history export mechanisms. This property does not apply to the MySQL device.

Local Time Stamp applies to Orion databases only and does not apply to history exports.

Utc Timestamp exports all subsequent histories with UTC timestamps.

Utc Millis applies to Orion databases only and does not apply to history exports.
Note: An Update Wizard is available to upgrade existing databases to support Unicode.
PointsfolderHolds all points.
Sql Scheme Enabledtrue or false (default)
Permits (true) and prohibits (false) the use of ORDs that contain sql:.

If a BFormat contains sql:, users can directly query the database bypassing framework access control and make direct changes to the database. This is a security risk. Best security practice sets this property to false.

Rdb Security Settingsadditional propertiesThe “rdb-RdbSecuritySettings” topic documents these properties.
Base Directorychooser
Defines the path that points to the location of the Hsql database. A typical configuration is to create a folder directly under the station (in the file space). For example, if the folder is named hsqldb, the filepath to this folder would be: file:^hsqldb.
Database Nametext
Provides the name of the database.
Defrag On Savetrue or false (default)
Configures the driver to defragment when it saves the database.
Defrag And Save Periodic Schedulecontrol-TimeTrigger with multiple propertiesGetting Started with Niagara documents these properties.

Actions

This component supports the following actions:

  • Ping sends a message to a network object (device, database, etc). The message provokes a response, which indicates the current state of the object.

  • Allow Dialect Modifications makes the Timestamp Storage property writable within the RdbmsNetwork Update Wizard. When the wizard converts a database to UTC (Coordinated Universal Time), it sets this property to read-only.

  • Defrag And Save sequences through the database to remove deleted records and save the resulting defragmented database.

  • Hsql Password opens a Password window that is used to change the Hsql password.

    Figure 2. Set Hsql Password window


    Although a new or upgraded HsqlDbDatabase automatically connects to the station using the factory-default password, you should always set a new strong password of your own in each controller station.

    The new password must meet the following requirements:

    • Length: at least 10 characters

    • Complexity: at least 1 digit, 1 upper case character and 1 lower case character.

    • Allowed character types:
      • lowercase letters
      • uppercase letters
      • special characters: @ # ! $ & + > < ] [ ) (