conditional Function | Vantage CX - conditional - Vantage Customer Experience

Vantage Customer Experience User Guide

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Vantage Customer Experience
Release Number
1.6
Published
October 2023
Language
English (United States)
Last Update
2023-10-26
dita:mapPath
hbt1563223944614.ditamap
dita:ditavalPath
oyf1565965838286.ditaval
dita:id
tmo1562969305444
Product Category
Teradata Applications

Controls the evaluation of other expressions in the entire expression tree. The conditional function is usually used as the first function in the expression stack.

conditional(
         get(”Account.dates.expiration”),
         NaN,
         false
) && 
set("fixedDateMillis", 
    time(get(get("Account.dates.expiration "),0),"day")
) && 
fixedDateMillis > time("2099-01-01T00:00:00.000Z","day")

This expression evaluates to false if there is no tag history for expiration dates in the session. The evaluation of the expression stops after the conditional function because the tag value is null and the get function evaluates to not a number (NaN), which is the second parameter in the conditional function. The third parameter is the value of the entire expression tree in this case. If there is tag history for expiration dates, the rest of the expression is evaluated.