Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

Analytics and Notifications for PI System Explorer (PI Server 2024 R2)

Convert

  • Last UpdatedJan 11, 2023
  • 1 minute read

Convert a value from its current unit of measure (UOM) to a specified UOM; for a value with no UOM, assign the specified UOM.

Syntax

Convert(x, toUnit)

Arguments

  • x

    Any expression that resolves to a numeric value, including the name of a numeric attribute enclosed in single quotation marks, a variable name, or a constant value

  • toUnit

    The output UOM enclosed in double quotation marks

Returns

The numeric value converted to the specified UOM

Exceptions

Returns an error if toUnit and the initial UOM for x are not in the same UOM class

Example

  • Convert('MetricWeight', "lb")

  • Convert('Ambient Temperature', "degC")

    Note: PI AF substitutes deg with °, if not otherwise found in the lookup.

In This Topic
TitleResults for “How to create a CRG?”Also Available in