exam questions

Exam PL-300 All Questions

View all questions & answers for the PL-300 exam

Exam PL-300 topic 2 question 25 discussion

Actual exam question from Microsoft's PL-300
Question #: 25
Topic #: 2
[All PL-300 Questions]

HOTSPOT -
You have a Power BI report.
You have the following tables.

You have the following DAX measure.
Accounts :=
CALCULATE (
DISTINCTCOUNT (Balances[AccountID]),
LASTDATE ('Date'[Date])
For each of the following statements, select Yes if the statement is true. Otherwise, select No.
NOTE: Each correct selection is worth one point.
Hot Area:

Show Suggested Answer Hide Answer
Suggested Answer:
Box 1: No -
It will show the total number of accounts that were live at the last day of the year only.
Note:
DISTINCTCOUNT counts the number of distinct values in a column.
LASTDATE returns the last date in the current context for the specified column of dates.

Box 2: No -
It will show the total number of accounts that were live at the last day of the month only.

Box 3: Yes -
Reference:
https://docs.microsoft.com/en-us/dax/distinctcount-function-dax https://docs.microsoft.com/en-us/dax/lastdate-function-dax

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
dorypl300
Highly Voted 2 years, 6 months ago
NO NO YES
upvoted 58 times
Alscoran
1 year, 4 months ago
I'm wondering if the last one is NO. A question for someone to clarify for me... Wouldn't DISTINCTCOUNT (Balances[AccountID]) be a distinct count of the BALANCES ? So if two accounts have the same balance, wouldn't it only count one time ? Thus giving an incorrect count of the active accounts ?
upvoted 1 times
jaume
5 months, 1 week ago
HI Alscoran, be aware DAX calculation is not counting (distinctcount) the amount for each balance but the [AccountID] therefore, even when two accounts could have exactly the same balance in the last day, they should be counted as 2 as they should not share the same Id)
upvoted 2 times
...
Alscoran
1 year, 4 months ago
I just realized that Balances is the table name, not a column. Ignore me !
upvoted 6 times
...
...
...
susunz
Highly Voted 2 years, 6 months ago
The date is hierarchy, the lastdate() is based on the hierarchy, which means the measure should be adjusted with the year/month/day level. Thus N-N-Y is correct.
upvoted 18 times
...
rcaliandro
Most Recent 8 months, 1 week ago
correct No, No, Yes
upvoted 1 times
...
Kiran37
9 months, 1 week ago
correct answer
upvoted 1 times
...
tke44
1 year, 10 months ago
NO NO YES
upvoted 4 times
...
lizbette
1 year, 12 months ago
shouldn't the last one be no too? the question says if it would calculate for the day, but doesn't it only calculate for the last day of the month? eg for the month of Jan, would only show Jan30; February would only show Feb28?
upvoted 1 times
joaowendling
1 year, 11 months ago
No, LASTDATE will return the last date from the current context. If the context is the Year, the last date will be 31/12/year. If the context is the Day, LASTDATE will return the day itself https://learn.microsoft.com/en-us/dax/lastdate-function-dax
upvoted 5 times
...
...
Nisa93
1 year, 12 months ago
NO NO YES
upvoted 3 times
...
yordiye
2 years, 3 months ago
No No Yes... Last Date calculates the last day only
upvoted 8 times
...
Jay_98_11
2 years, 5 months ago
correct
upvoted 2 times
...
Churato
2 years, 6 months ago
As I was no sure , I did a test here, and Yes, the answer is correct...
upvoted 3 times
...
Mizaan
2 years, 6 months ago
Shouldn't this be YYY? Lastdate "returns the last date in the current context for the specified column of dates". Therefore, it will be give you the last day of the year or month depending on the context. If you then do a distinctcount on the accountid, this means that account had a closing balance on that day.
upvoted 2 times
shakes103
2 years, 5 months ago
It is NO NO YES and here's why. Just as you mentioned, Lastdate "returns the last date in the current context for the specified column of dates" which means it will ONLY RETURN the live account balances for the LAST DAY of the YEAR for year and MONTH for month and not THROUGHOUT THE YEAR & THROUGHOUT THE MONTH as those options stated. Read those options again and the answers will come to you.
upvoted 23 times
JudT
1 year, 1 month ago
Correct. Understood now! Cheers Shakes103
upvoted 2 times
...
...
...
lukelin08
2 years, 6 months ago
No No Yes
upvoted 6 times
...
aloulouder
2 years, 7 months ago
correct
upvoted 5 times
...
simplex06
2 years, 7 months ago
It should be No - No - Yes
upvoted 5 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago