How does the TRUNC function (DAX) work?
The TRUNC function (DAX) removes the fractional part of a number and, thus, truncates a number to an integer.
TRUNC Formula Syntax
How do you use the TRUNC function?
Use the TRUNC function to remove the fractional part of a number and return just the integer. For example, TRUNC(4.9) will return 4, and TRUNC(-3.5) will return -3. TRUNC does not do any rounding, it simply returns the integer part of the number.
Related Blog Posts
Related Support Forum Posts
Considerations when using the TRUNC function
The TRUNC and INT are similar in that both return integers. TRUNC removes the fractional part of the number. INT rounds numbers down to the nearest integer based on the value of the fractional part of the number. INT and TRUNC are different only when using negative numbers: TRUNC(-4.3) returns -4, but INT(-4.3) returns -5 because -5 is the lower number.
Related Video Tutorials
Formula examples using the TRUNC function