Many of the advanced features of Ignition, such as the Transaction Groups and Tags Historian require a connection to an external database and most databases require special permissions for each computer that wants to connect. Fortunately Ignition takes care of all of this for us. You can create a connection to your database once and every system in Ignition will use that central connection. There's no need to worry about updating your database settings to add another client.
This central database connection also makes it easy to swap between databases or schemas. You can tell every query to use the default connection, then just change the default to update everything. Alternatively, you can force specific queries or systems to use a particular connection. Create as many database connections as you want and start designing using all of them.
Now that we've installed your database, lets connect to it. You can find detailed descriptions for many database connections in this User Manual, however they all include the following three main steps:
Configure the Connection
After selecting the driver, you'll configure the settings for the connection. Some settings, such as the Connect URL are specific to the driver that you're using.
Main Database Connection Properties
|Name||Each database connection needs a unique name, which consists of letters, numbers and underscores.|
|Description||A brief description of the database.|
|JDBC Driver||The JDBC driver dictates the type of database that this connection can connect to. It cannot be changed once created.|
|Connect URL||A string that instructs the driver how to connect to the database. This string is the server address, and may include the port, instance name, database name, and so on. The format and parameters depend on the driver being used.|
|Username||The username to use when connecting. Some databases support other authentication methods, such as Windows authentication, in which case this field is not used.|
|Change Password?||Check the box to change the existing password.|
|Password||Re-type password for verification.|
|Extra Connection Properties||Depending on which database you are connecting to, there will be different default values placed in this box. MS SQL Server requires you to place your database name here, but for other databases you can usually leave this at its default values.|
Each database has its own set of available extra connection properties so you must refer to your Database documentation to determine what is valid here.
|Enabled||Lets you to enable or disable a database connection.|
|Validation Timeout||The time in milliseconds between database validation checks. (default: 10,000)|
|Failover Datasource||The connection that is automatically used when this connection is not available.|
|Failover Mode||Lets you select how to handle the database connection failing and recovering. |
Database connections support failover, this means that the objects which use a database connection, will use a different connection if the one they are using becomes unavailable. The Failover Datasource property determines which connection is used, and the Failover Mode determines when, if ever, the connection is switch back to the primary connection.
There are two failover modes:
• STANDARD mode means that this datasource will fail over when a connection cannot be retrieved, but when connectivity is restored, connections will again come from this datasource.
• STICKY mode means that once this datasource fails over, connections will continue coming from the failover datasource until the failover datasource itself fails or the Gateway is restarted.
|Slow Query Log Threshold||Queries that take longer than this amount of time, in milliseconds, will be logged. This helps to find queries that are not performing well. (default: 60,000)|
|There are a many advanced settings that you don't need to change under normal circumstances. See the description for each property on the settings page.|