View raw Markdown
type: fhirpath-operatoroperator: modcategory: Mathsection: 6.6.6source: fhirpath/operations.json

FHIRPath Operator: mod (mod)

Computes the remainder of the truncated division of its arguments (supported for Integer and Decimal).

5 mod 2 // 1
5.5 mod 0.7 // 0.6
5 mod 0 // empty ({ })

Summary

Description

Computes the remainder of the truncated division of its arguments. Supported for Integer and Decimal. Each operand must be a single element. Modulo by zero results in empty collection.

Type Mapping