ValueForEntity

Returns the value of a specific signal for a specific entity. The value returned will be in numeric or string format depending on the signal type.

Syntax

ValueForEntity(“Signal name” in “Unit“, "Entity name")

ValueForEntity(“Water production rate” in “STB/day“, "Well 1") 

Parameters

  • Signal name: Provide the specific signal name that’s needs to be returnes
    • g (“Oil production rate” in “bbl/day.”)
  • Unit: Specify the Unit you want the results in. If a different unit from the signal default unit is selected, The value is automatically converted.
    • g (“bbl” -> “L”)
  • Entity Name: Name of a specific entity or well.

Return value

  • String, Numeric or null value corresponding to the given Signal value.
  • Returns value types depend on what the signal type is. If deriving values from a numeric time signal, the value returned will be numeric.
  • String values can also be derived from the signal as string type values.

Exceptions

Throws an error if Entity or Signal do not exist in the workspace.

 

Example

The logic filters for “cumulative oil production” highest than 100,000 bbl and then populates the signal “high oil cumulation” with only those values/ signals.

 

Table "Cumulatives"
Column "High Oil Cumulatives" in "bbl" saving "high oil cumulatives"
If
ValueForEntity("cumulative oil production" in "bbl", CurrentEntity())) >=100000
Then
"cumulative oil production" in "bbl"
Else
null()
End if
End Column
End Table

Results

 

Example

This logic extracts string values from a string signal and returns Boolean value to see if the string values equals "Rod pump"

Table "Rod Pump wells"

Column "Rod pumps" in " "

ValueForEntity("artificial lift method" in "", CurrentEntity()) = "ROD PUMP"

End Column

End Table

Results