Math Functions
The math functions perform mathematical operations.
ABS
This function calculates the absolute value of a numeric expression.
Syntax
ABS(numExpr)
Where:
numExpr
is any expression that evaluates to a numeric value.
Example:
ABS(TIMESTAMPDIFF(SQL_TSI_DAY, "Submission Dates"."Submission Created Date", "Submission Dates"."Hire Start Date"))
This will give you the absolute value of the days between the Submission Created Date and the Hire Start Date. If the Hire Start Date is before the Submission Creation Date resulting in negative days between, ABS will give you the positive equivalent. For example, if days between is -2, ABS will show a value of 2.
CEILING
This function rounds a noninteger
numeric expression to the next highest integer. If the numeric expression
evaluates to an integer, the CEILING
function returns
that integer.
Syntax
CEILING(numExpr)
Where:
numExpr
is any expression that
evaluates to a numeric value. FLOOR
Example:
CEILING("Candidate Counts"."# Submissions Complete"/"Candidate Counts"."# Submissions")
This will round the ratio value to the next highest integer.
This function rounds a noninteger numeric expression
to the next lowest integer. If the numeric expression evaluates to
an integer, the FLOOR
function returns that integer.
Syntax
FLOOR(numExpr)
Where:
numExpr
is any expression
that evaluates to a numeric value.
Example:
FLOOR("Candidate Counts"."# Submissions Complete"/"Candidate Counts"."# Submissions")
This will round the ratio value to the next lowest integer.
RAND
Returns a pseudo-random number between 0 and 1.
Syntax
RAND()
This function rounds a numeric expression to n digits of precision.
Syntax
ROUND(numExpr, integer)Where:
numExpr
is any expression
that evaluates to a numeric value.
integer
is any positive integer that represents the number of digits of
precision.
Example:
ROUND("Candidate
Counts"."# Submissions Complete"/"Candidate Counts"."# Submissions",3)This will round the value of the ratio to 3 digits.
NOTE: The Data Format in Column Properties will need to be configured to more than 2 digits to see up to the 3 digits specified in the formula.
TRUNCATE
This function truncates a decimal number to return a specified number of places from the decimal point.
Syntax
TRUNCATE(numExpr, integer)
Where:
numExpr
is any expression
that evaluates to a numeric value.
integer
is any positive integer that represents the number of characters
to the right of the decimal place to return.
Example:
TRUNCATE("Candidate Counts"."# Submissions Complete"/"Candidate
Counts"."# Submissions",3)This will remove the characters after the third decimal place without rounding the number. If the ratio yields 0.8745, TRUNCATE will show 0.874 (ROUND will show 0.875).
NOTE: The Data Format in Column Properties will need to be configured to more than 2 digits to see up to the 3 digits specified in the formula.