Scalar FunctionsOther Functions
otel_histogram_percentile
Extract a percentile from a merged OpenTelemetry histogram (output of otel_histogram_merge). Returns NaN for null, empty, or invalid histogram input, and for percentile values outside 0-100. For explicit histograms, uses linear interpolation within the target bucket. For exponential histograms, uses the geometric midpoint of the target bucket.
Syntax
otel_histogram_percentile(histogram, percentile)Parameters
Prop
Type
Returns: real
Examples
Example 1
metrics
| where metric.type == "histogram" and metric.name == "http.request.duration"
| summarize merged = otel_histogram_merge($raw) by bin($time, 1h)
| project otel_histogram_percentile(merged, 50)