0
0
Power BIbi_tool~10 mins

DATEADD for period shifts in Power BI - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to shift the date by one month using DATEADD.

Power BI
ShiftedDate = DATEADD('Calendar'[Date], [1], MONTH)
Drag options to blanks, or click blank then click option'
A0
B-1
C12
D1
Attempts:
3 left
💡 Hint
Common Mistakes
Using 0 will not shift the date.
Using -1 shifts the date backward, not forward.
2fill in blank
medium

Complete the code to shift the date by three quarters backward.

Power BI
ShiftedDate = DATEADD('Calendar'[Date], [1], QUARTER)
Drag options to blanks, or click blank then click option'
A3
B-3
C1
D-1
Attempts:
3 left
💡 Hint
Common Mistakes
Using positive 3 shifts forward instead of backward.
Using 1 or -1 shifts by only one quarter, not three.
3fill in blank
hard

Fix the error in the code to correctly shift the date by one year forward.

Power BI
ShiftedDate = DATEADD('Calendar'[Date], [1], YEAR)
Drag options to blanks, or click blank then click option'
A1
B12
CYEAR
D'1'
Attempts:
3 left
💡 Hint
Common Mistakes
Putting the interval type as the second argument.
Using a string instead of a number for the shift amount.
4fill in blank
hard

Fill both blanks to shift the date by two weeks backward.

Power BI
ShiftedDate = DATEADD('Calendar'[Date], [1], [2])
Drag options to blanks, or click blank then click option'
A-2
B2
CWEEK
DMONTH
Attempts:
3 left
💡 Hint
Common Mistakes
Using positive 2 shifts forward instead of backward.
Using MONTH instead of WEEK for weekly shifts.
5fill in blank
hard

Fill all three blanks to shift the date by five days forward.

Power BI
ShiftedDate = DATEADD([1], [2], [3])
Drag options to blanks, or click blank then click option'
A'Calendar'[Date]
B5
CDAY
D'Sales'[Date]
Attempts:
3 left
💡 Hint
Common Mistakes
Using a non-date column as the first argument.
Using negative number to shift forward.
Using MONTH or WEEK instead of DAY.