PL-400 practice question 6 of 35

You need to configure the trigger for account records. Which expression should you use?

Full set: 391 questions

Domain Configure Microsoft Dataverse

Answer options
A: ADDWEEKS(1, CreatedOn)
B: ADDDAYS(10, CreateOn)
C: SUBTRACTDAYS(10, Now())
D: DIFFINDAYS(CreatedOn, now()) Correct answer
E: DIFFINWEEKS(now, 1)
Correct Answer:
D. DIFFINDAYS(CreatedOn, now())
Explanation

The question requires an expression suitable for a time-based trigger condition related to a record's creation date. The DIFFINDAYS(date1, date2) function is specifically designed for this purpose within Dataverse calculated columns. It calculates the difference in days between two dates. Using DIFFINDAYS(CreatedOn, now()) directly computes the age of the account record in days. This resulting integer value can then be easily used in a Power Automate flow trigger condition, a business rule, or a view filter to initiate an action when the account reaches a specific age (e.g., when the result is greater than or equal to 10).

Why Incorrect

A. ADDWEEKS(1, CreatedOn) calculates a future date. While usable in a comparison, it is less direct than calculating the elapsed time.
B. ADDDAYS(10, CreateOn) calculates a future date. It is an indirect method for checking a record's age compared to DIFFINDAYS.
C. SUBTRACTDAYS(10, Now()) calculates a past date. This can be used for comparison but is less straightforward than directly calculating the age of the record.
E. DIFFINWEEKS(now, 1) is syntactically incorrect. The DIFFINWEEKS function requires two date/time parameters, not a date and an integer.

References

1. Microsoft Learn | Dataverse Documentation. Define calculated columns to automate manual calculations. This document lists the available functions for calculated columns in Dataverse, including DIFFINDAYS, ADDDAYS, and NOW().

Reference: Under the section "Date and Time functions," the table explicitly lists DIFFINDAYS (date and time, date and time) with the description "Returns the difference in days between two Date and Time columns." The NOW() function is also described as returning the current date and time.

2. Microsoft Learn | Dataverse Documentation. Work with operators and functions in business rules, business process flows, and classic workflows. This guide details the functions available in the classic workflow and business rule editor.

Reference: The section on "Date/Time Functions" confirms the availability and syntax of functions like DIFFINDAYS, which are used to build conditional logic based on date differences.

Scroll to Top