Configure table lookup data references
- Last UpdatedJan 11, 2023
- 3 minute read
- PI System
- PI Server 2024 R2
- PI Server
Create a table lookup data reference when you want an attribute to obtain its value from a table column.
-
In the Elements or Library browser, select the desired element or element template.
-
In the viewer, select the attribute or attribute template for which you want a table lookup value.
-
In the Data Reference field in the palette, choose Table Lookup from the list.
-
Click Settings.
-
In the Table Lookup Data Reference window, select a previously defined table from the Table drop-down list. You can also choose from the following options:
-
Click
(Manage Tables) to open a list of tables you can search or filter. To select a table,
highlight it in the list and click OK.
-
Click
(Table Properties) to view or edit properties for the selected table.
-
Click
(Create New Table) to define a new table.
-
-
From the Result column list, select the column in the table from which you want to read the value.
Note: Select the Stepped check box for the value to be stepped when plotted in a trend. With this setting, there is no interpolation between the table values.
-
From the Unit of Measure list, select the appropriate unit of measure in which the data in the result column is stored.
Note: It is preferable to set the UOM directly in the table definition so that you do not need to specify it with each table lookup.
-
In Time Zone, you can define a setting if it has not previously been set in the table or column definition.
-
From the Rule list, choose an option:
-
Select first row matching criteria
Use the Order by list to specify the sorting order. This order is used to select a row when more than one row matches the criteria. For more information, see Select first row matching criteria.
-
Summarize all rows matching criteria
Select a summary operation from the Summary list to perform the selected operation on the selected column over the range of rows that match the criteria. For more information, see Summarize all rows matching criteria.
-
Table provided time series data
Choose this option if the table has values with associated time stamps and you wish to treat these values as time series data. From the Time Column list, select the table column that contains the time stamps you want to use. Only columns with a value type of DateTime are listed. The WHERE clause is not required when you choose this option. For more information, see Table provided time series data.
Note: To ensure that columns with DateTime value types are displayed, only specify time zone settings on the General tab of the overall table definition. Do not specify time zones on the column definition (on the Define Table tab).
-
-
In the Where pane, use the menus and buttons to build the table query.
Note: You can manually type the entire clause into the Complete WHERE Clause text field. See WHERE clause syntax for more information.
-
From the Column list, select the column of the table to use in the query.
-
From the Operator list, select the relational operator to use in the query.
-
From the Attribute or Value list, select an attribute or a literal value to use in the query.
-
Click Add And or Add Or to write the WHERE clause into the Complete WHERE Clause field with an AND or an OR operator.
-
Edit the clause in the Complete WHERE Clause field as needed.
Note: The Add And or Add Or buttons automatically generate the necessary syntax, UOM, and time zone conversions when possible.
-
-
Optional. Edit values for table parameters.
Table parameters apply only to linked tables. For more information, see Parameters for linked table queries.
-
Optional. For Replacement Values, choose attributes or literal values to return when the table query cannot find a matching row or encounters a null result.