All articles

Formula Custom Fields: Possible Formulas and Resulting Data Types

Table 15. Availability

Free

Professional

Business

Enterprise


Overview

Formula custom fields allow you to add calculations to the data that you enter in your custom and system fields. You can add different types of fields to one formula, but the calculated result can only be one type.

Possible formulas and resulting data types

Let’s say we need to calculate the total payment for an employee who charges per hour:

Formula example: [Hourly Rate]*[Time Spent]=Currency

The field [Hourly Rate] has the Currency data type, and the field [Time Spent] is set as Hours. The resulting field type of calculation will be Currency.

The table below shows which types of fields can be included in formulas together, which math operation can be applied to them, and what the resulting data type will be.

  1. Choose the data type of the first field in the formula from the first column on the left.

  2. Underneath it, choose the row with the required math operation.

  3. Follow the row to the column with the data type of the second part of the formula.

Note

The order of fields in the formula determines the resulting type of data. For example, if you divide Number by Hours, the resulting type will be Number. But if you switch the fields in the formula and divide Hours by Number, the result will be Hours.

Number

Currency

Percentage

Days

Hours

Date

Number

+, -

Number

Currency

Number

Days

Hours

Date

*

Number

Currency

Number

Days

Hours

-

/

Number

Number

Number

Number

Number

-

Currency

+, -

Currency

Currency

Currency

Number

Number

-

*

Currency

Number

Currency

Currency

Currency

-

/

Currency

Number

Number

Currency

Currency

-

Percentage

+, -

Number

Currency

Percentage

Number

Number

-

*

Number

Currency

Percentage

Days

Hours

-

/

Percentage

Number

Number

Number

Number

-

Days

+, -

Days

Number

Number

Days

Hours

Date

*

Days

Currency

Days

Number

Hours

-

/

Days

Number

Days

Number

-

-

Hours

+, -

Hours

Number

Number

Hours

Hours

Date

*

Hours

Currency

Hours

Hours

Number

-

/

Hours

Number

Hours

Number

Number

-

Date

+

Date

-

-

Date

Date

-

-

Date

-

-

Date

Date

Days

Important

  • Duration custom fields and Time Spent system fields are calculated in hours.

  • Duration system field (i.e., duration of tasks and projects) is treated as days.

Tip

You can always check any of your custom field types in the custom field management panel.

Top