0
0
Tableaubi_tool~10 mins

Continuous vs discrete dates in Tableau - Interactive Practice

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

Complete the code to create a continuous date axis in Tableau.

Tableau
DATEPART("[1]", [Order Date])
Drag options to blanks, or click blank then click option'
AMONTH
BYEAR
CDAY
DWEEK
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing MONTH or DAY creates discrete segments, not continuous.
2fill in blank
medium

Complete the code to create a discrete date field in Tableau.

Tableau
DATETRUNC("[1]", [Order Date])
Drag options to blanks, or click blank then click option'
AHOUR
BDAY
CYEAR
DMONTH
Attempts:
3 left
💡 Hint
Common Mistakes
Using YEAR creates yearly grouping, which can be continuous or discrete depending on context.
3fill in blank
hard

Fix the error in the year comparison calculation.

Tableau
IF DATEPART("year", [Order Date]) = [1] THEN [Sales] END
Drag options to blanks, or click blank then click option'
A2023
B"2023"
C"Year"
DYear
Attempts:
3 left
💡 Hint
Common Mistakes
Using quotes around numbers causes type mismatch errors.
4fill in blank
hard

Fill both blanks to sum sales for January 2023.

Tableau
SUM(IF DATETRUNC("[1]", [Order Date]) = [2] THEN [Sales] ELSE 0 END)
Drag options to blanks, or click blank then click option'
AMONTH
BDATE("2023-01-01")
CYEAR
DDATE("2023-02-01")
Attempts:
3 left
💡 Hint
Common Mistakes
Using YEAR truncation or wrong date values causes incorrect grouping.
5fill in blank
hard

Fill all three blanks to create a discrete date filter for sales in January and February.

Tableau
IF DATENAME("[1]", [Order Date]) IN ([2], [3]) THEN [Sales] ELSE 0 END
Drag options to blanks, or click blank then click option'
AMONTH
B"January"
C"February"
D"March"
Attempts:
3 left
💡 Hint
Common Mistakes
Using YEAR or QUARTER instead of MONTH causes wrong filtering.