Show TOC

Procedure documentationODBC Destination System: Configuration Tab


On this tab, you set up the connection to the database and create the table in which you want the values of the subscribed tags to be stored later. (See also: ODBC Destination System.) The following database types can be used:

  • MS SQL Server 2008

  • SAP HANA database


You have created and configured the data source that you want to use for your database in the ODBC Data Source Administrator. (See Setting Up the Connection to the SQL Server and Setting Up the Connection to the SAP HANA Database.)


Create ODBC Destination System
  1. Choose the Add Destination System pushbutton and then choose the destination system type ODBC destination system.

    The Configuration tab appears.

  2. You establish the connection to the desired database in the ODBC data source screen area.



    Data Source

    Choose the ODBC data source that you created previously in the ODBC Data Source Administrator for your database.

    User Name and Password

    Enter the logon data for the ODBC data source that you created previously in the ODBC Data Source Administrator for your database.

  3. Choose the Test Connection pushbutton to check if a connection has been established.

Create Table

You can create a table in PCo with a predefined structure. This table is created automatically in the connected database after saving. On creation, this table already contains a data record that you need to configure. The data record consists of the following four table fields. In the database, these table fields form the columns of the history table that are then filled with values when the agent instance is running.

  • IID: Tag ID

  • IQUALITY: Quality of the Tag Value

  • ITIMESTAMP: Time Stamp

  • IVALUE: Tag Value

  1. To create a new table, choose the Create Table pushbutton in the Definition of Table Records screen area.

    The Create Table dialog box appears.

  2. Enter the name of the table.

    The table name is structured as follows:


    Example Example


    End of the example.

    Entering the database schema is optional. If you do not enter anything, PCo automatically uses the user name that you use to log on to the database as the schema.

    Example Example

    User name Mustermann and table name TAG_History lead to MUSTERMANN.TAG_HISTORY.

    End of the example.

    The system then displays a table with a data record. The names of the four table fields are hard-coded and cannot be changed.

  3. Define the settings for the data record (see Add Record).

Add Record

If you have already created a table, you can choose this table and add as many records to it as you want.

  1. Choose the Add Record pushbutton to select the table you want and to add a new data record.

    The Choose History Table dialog box then appears.

  2. If necessary, enter PCO in the Filter field, if a great many tables are displayed for selection. The system then only displays the PCo-relevant tables.

  3. Select the table you want.

    The system now displays a new data record in the form of a predefined assignment table. The following example shows the structure of a data record:




    Indicates that an entry is necessary for this table field. In this case, an asterisk (*) is displayed.

    Note Note

    An asterisk (*) is always displayed in the following cases:

    • SQL type of the table field is INTEGER

    • SQL type of the table field is TINYINT

    • You have selected the column Not Null for a table field for a user-defined table in the HANA DB.

    End of the note.


    In the first row of a data record, the name of the history table for which you want to create a data record is specified. In the following rows, the table fields of the table are displayed, for example, ITIMESTAMP.


    Specifies the SQL type of the table field. The ID, for example, always has the type INTEGER.


    Here you specify a value for the table field. If it is a variable, the following applies: The variable must start with a letter. The variable must only consist of letters, digits, and underscores, for example, VAL1.

    Is Variable

    By selecting this checkbox, you specify that the entry in this row is to be a variable.

    If you do not select the checkbox, the table field is treated as a constant.

  4. Enter a value for each table field. Specify for each table field if it is a variable or a constant by selecting the Is Variable checkbox for a variable.

    Example Example





    Is Variable



    Pushbutton for deleting the entire data record is displayed.




    Enter 1, for example.

    No selection required because it is a constant.




    Enter 1, for example.

    No selection required because it is a constant.



    Enter TS1, for example.

    Set selection for variable.



    Enter VAL1, for example.

    Set selection for variable.

    End of the example.

    The entries are a prerequisite for PCo being able to assign the subscribed tags to the variables, and for the tag values, which are sent using the notification messages, being written later to the history table on the database.