rdbSqlServer-SqlServerDatabase

This component models an Microsoft SQL Server database versions: SqlServer 2000, SqlServer 2005, SqlServer 2008, SqlServer 2008 R2 and SqlServer 2012. It is available in the rdbSqlServer palette.
Figure 26.   SqlServerDatabase properties
Image

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

The Rdbms driver supports connecting to the SQL Server instances that are configured for the use of the Windows Authentication mode.

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

Property Value Description
Host Address (database device components) IP address
Sets the IP address or hostname of the computer platform where the database resides. A Dialup selection option is available, if required. This property does not apply to the MySQL device.
Use Encrypted Connection true 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 Name (database device components) text
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

Password (database device components) text
Defines the password required to log in to the database. The Confirm property must be an exact match to the Password property.
Worker additional properties The “rdb-RdbmsWorker” topic documents these properties.
Export Mode (database device components) drop-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 Scheme (database device components) true 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 Storage enum property drop-down list (defaults to Dialect Default)
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. 

Points folder Holds all points.
Sql Scheme Enabled (database device components) true 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 Settings additional properties The “rdb-RdbSecuritySettings” topic documents these properties.
Tls Min Protocol drop-down menu
Selects the minimum TLS protocol that can be negotiated when establishing encrypted communications with a database server.
Verify Subject In Certificate true (default) or false
If set to true, the Rdbms driver verifies that the Subject present in the server’s certificate matches an expected value. The value used for the comparison to the Subject in the server’s certificate is specific to each Rdbms device type.
Instance Name text Configures a connection to a SqlServer database if the user has not been previously set up in the SqlServer with a default Database Name or Instance Name, or to connect to a name that is not the default. If a default name has been set up and you need to connect to it, you can leave this property blank.
Port number (the default value depends on the rdb Database type)
Specifies the port number to use when connecting with the database. Defaults are:

HsqlDbDatabase, no port specified because this rdb is for local database use only:

MySQLDatabase: 3306

OracleDatabase: 1521

SqlServerDatabase: 1433

Histories additional properties “rdbMySQL-MySQLHistoryDeviceExt” documents these properties.
Extra Connection Properties (MySQL and SqlServer devices only) normally left blank; if used takes the format: parameter1=value1;parameter2=value2;...etc.

Provides additional configuration properties that are not required for a normal connection to the database. These configuration options are passed directly to the JDBC driver to configure advanced JDBC driver options.

You can set certain configuration properties as part of the extra connection properties of the RDBMS database to optimize the batch processing of the insert queries, specifically the history export queries.

Version drop-down list, defaults to Sql Server 2008 Determines if the Sql Server database supports the SQL DATE type. The DATE Sql type is supported from Sql server 2008 onwards and the database device needs to know how to translate timestamps when retrieving records. Set this property to match the version of the database you are connecting to.

Sql Server 2008 specifies that the Version of Sql Server you are connecting to is Sql Server 2008.

 NOTE: Use this option to connect to an Sql version that is more recent than Sql Server 2008, such as Sql Server 2012. 

Sql Server 2005 specifies that the Version of Sql Server you are connecting to is Sql Server 2005.

Sql Server 2000 specifies that the Version of Sql Server you are connecting to is Sql Server 2000.

Sql Server Cert drop-down list
Defines the database server certificate for TLS secure communication.

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.

Dynamic ports in the RdbSqlServer

SqlServerDatabase supports connecting to an SQL Server Named Instance using dynamic port discovery. To configure the use of dynamic ports, the port property must be set to 0, and the instance Name parameter value corresponding to the desired Named Instance must be specified in the Extra Connection Properties.

For example, to connect to an SQL Server Named Instance, named as MSSQLSERVER that is configured to use dynamic ports, set the Port property to 0 and add instanceName=MSSQLSERVER to the ExtraConnectionProperties property.

Refer to the “Dynamic ports in the RdbSqlServer” for more details.