Previous Topic

Next Topic

Book Contents

Line Item Functions

Math Functions (+, -, *, /). BigTime supports basic mathematical calculations (addition, subtraction, multiplication, division of two values).

CEILING(<MaximumAmount>, <Value>). This function caps the values returned by a <MaximumAmount>. If <Value> is greater than <MaximumAmount>, then the function returns <MaximumAmount>. Otherwise, <Value> is returned.

CEILING(10,10.5) will return 10, but CEILING(10,9.5) will return 9.5.

FLOOR(<MinimumAmount>, <Value>). FLOOR provides a way to set a minimum amount that the function is allowed to return. If <Value> is less than <MaximumAmount>, then the function returns <MaximumAmount>. Otherwise, <Value> is returned.

FLOOR(0,100) will return 100, but FLOOR(0,-100) will return 0.

IIF(<LogicalComparison>,<TrueResult>,<FalseResult>). This function lets me return one of two values based on a logical condition. If <LogicalComparison> is TRUE, then <TrueResult> is returned. Otherwise, <FalseResult> is returned.

IIF(1>0,100,0) will return the value 100 (because 1>0 is TRUE). IIF(0>1,100,0) will return zero (because 0>1 is FALSE).

Square Brackets ("[ ]") in Invoice Formula

Note that invoice formula also make use of the square bracket instead of parenthesis to block out terms that contain a calculation. A typical FLOOR function, for example, may look like this:

FLOOR(0,[TIME_CHG-RETAINER])

We have to set apart the calculation TIME_CHG-RETAINER, so the invoicing engine knows to process that calculation first, before applying the FLOOR function's logic. Square brackets are used instead of parens, and that's different than most formula editors. Keep that in mind as you start work on your own custom line item formula!

See Also

Invoice Templates

Who Should Read This Chapter

Editing Invoice Templates

T&M Invoicing Explained

Invoice Sub-Totalling

Additional Template Examples

Line Item Variables