Follow
Condition Operators in Calculated Custom Expressions

You can use condition operators when building calculated custom data in Workfront. They help building a condition statement by connecting existing Workfront fields in statements and generating a new field. The most common use of condition operators is to build the condition of an "IF" statement.

You can use "IF" statements in Workfront to compare, format, and string together fields of data for both reporting and custom data purposes.

You can build "IF" statements for the following Workfront elements:

  • Views
  • Groupings
  • Calculated Custom Fields

For more information about building "IF" statements, see ""IF" Statements Overview."

The examples in this guide illustrate the use of condition operators in calculated custom fields. You can also use them in calculated custom columns or groupings as well, when following the correct syntax for calculated custom fields in reports.

For information about the difference in syntax between the calculated custom fields and calculated custom data in reports, see "Calculated Custom Fields vs Calculated Custom Columns."

Refer to the API Explorer to find the fields you want to reference in your calculated custom expressions. For information about the API Explorer, see "API Explorer."

You can use the following condition modifiers in Workfront:

Condition Modifier Condition Modifier Syntax Condition Modifier Definition
Equal =

Use this modifier to indicate that the condition is fulfilled when the first field of your statement is equal to the second field.

For example, use the following statement in a calculated custom field to build an "IF" statement that compares the Planned Completion Date to the Projected Completion Date of a task:

IF(Projected Completion Date=Planned Completion Date,"On Track","Off
          Track")
Greater than > Use this modifier to indicate that the condition is fulfilled when the first field of your statement is greater than the second field.

For example, use the following statement in a calculated custom field to build an "IF" statement that compares the Planned Completion Date to the Projected Completion Date of a task:

IF(Projected Completion Date>Planned Completion Date,"Late","")
Greater than or equal to >= Use this modifier to indicate that the condition is fulfilled when the first field of your statement is either greater than or equal to the second field.

For example, use the following statement in a calculated custom field to build an "IF" statement that compares the Planned Completion Date to the Projected Completion Date of a task:

IF(Projected Completion Date>=Planned Completion Date,"Late","Early")
Lesser than  < Use this modifier to indicate that the condition is fulfilled when  the first field of your statement is lesser than the second field.

For example, use the following statement in a calculated custom field to build an "IF" statement that compares the Planned Completion Date to the Projected Completion Date of a task:

IF(Projected Completion Date<Planned Completion Date,"Early","")
Lesser than or equal to <= Use this modifier to indicate that the condition is fulfilled when  the first field of your statement is lesser than or equal to the second field.

For example, use the following statement in a calculated custom field to build an "IF" statement that compares the Planned Completion Date to the Projected Completion Date of a task:

IF(Projected Completion Date<=Planned Completion Date,"Early","Late")
Does not !

Add this operator in front of any of the above operators to negate the operator.

For example:

  • Equals: =
  • Does not equal: !=

Adding this operator in front of the following data expressions adds a negative statement to expressions:

  • CONTAINS
  • IN
  • IFIN
  • ISBLANK

For information about these data expressions and for a complete list, see "Understanding Calculated Data Expressions."

Or ||

Use this modifier to indicate that the condition is fulfilled when the expression  finds either the first or the second value of your statement.

For example, use the following statement in a calculated custom field to build an "IF" statement that marks projects in either the Current or Planning statuses as "Active":

IF(Status="PLN"||Status="CUR","Active","Not Active")
 And &&

Use this modifier to indicate that the condition is fulfilled when the expression  finds an item that fulfills two conditions at the same time.

For example, use the following statement in a calculated custom field to build an "IF" statement that finds projects that are in Current status and have a Condition of At Risk and marks them as "Mediation Needed."

IF(Status="CUR"&&Condition="AR","Mediation Needed","")

 

 

This article last updated on 2019-02-22 14:25:58 UTC