TDA-C01 Exam QuestionsBrowse all questions from this exam

TDA-C01 Exam - Question 33


You have the following visualization.

The Last() calculation is set to compute using Table (across).

Which value will appear in the crosstab for the Consumer segment of the year 2018 if you change compute to use Order Date?

Show Answer
Correct Answer: B

When you set LAST() to compute using Order Date, it will calculate the position of each row relative to the last row in the partition. In this case, the year 2021 is the last order date, which would correspond to 0 when computing LAST(). Moving backwards, 2020 would be 1, 2019 would be 2, and 2018 would be 3. Therefore, the value that appears in the crosstab for the Consumer segment of the year 2018 would be 3.

Discussion

5 comments
Sign in to comment
CollectiveConsciousnessOption: B
Feb 2, 2024

The answer is incorrect. last() uses 0 inclusively, therefore the highest value we can obtain is 3. When computed by order date, it would consider the latest date 0 while the 2018 date as a 3.

asiat2301
Nov 24, 2024

Please why 3. the value of 2018 is 4. you correct me

MonBouj
Nov 29, 2024

It starts with 0 not 1

MonBouj
Nov 29, 2024

It starts with 0 not 1

JUT_TC
Mar 24, 2024

3 is the answer

Gili_1370
Jun 27, 2024

B:3 ist the answer

MonBoujOption: B
Nov 29, 2024

B. 3 (tested)

ShazzyHawkOption: B
Apr 30, 2025

LAST() gives the number of rows from the current cell to the last cell in the partition. When Compute Using is Order Date (i.e., down the table), it processes data vertically for each Segment column. So for the Consumer segment, here's what LAST() returns for each year (since the partition is vertical for that segment): 3