HasDataPoints (PQL)
Returns the numeric expression value if the current datapoint contains any of the provided datapoints, otherwise returns null.
- Returned Output: Numeric
- Library: PQL \ Semantic \ Logical
- Version: 2023.10.000
- Compatibility: Pyramid Query Language (PQL) data sources
Syntax
HasDataPoints( <Data Point N> , <Data Point> )
* Click on the function's arguments above for more details on the input values.
Comments
The HasDataPoints function returns the value of the last numeric data point if the current value is among the first N data points:
- The first n data points list the members that you are checking against the current data point.
- If the current data point is among the first n data points, the match is true and either:
- The last data point (a numeric value) is returned.
- If this value is not supplied, the function returns
null
.
Examples
The following example checks the current dataset to find out if it contains the specified data points. If it does, it returns the final, numeric value. Otherwise it returns null
:
HasDataPoints( ([Customer].[Country].[Australia]), ([Customer].[Country].[France]), [measures].[Sum returns] )