exam questions

Exam PL-400 All Questions

View all questions & answers for the PL-400 exam

Exam PL-400 topic 3 question 30 discussion

Actual exam question from Microsoft's PL-400
Question #: 30
Topic #: 3
[All PL-400 Questions]

You are creating a canvas app that realtors use to identify neighbors for properties that are for sale.
The OnStart property includes the following code:
ClearCollect(collectNeighborList, Filter(NeighborList, Status = `Active")); ClearCollect
(collectRealtorList,CompanyList);ClearCollect(collectRegions, RegionList)
The app is running slower than expected.
You need to resolve the issue.
What should you do?

  • A. Replace all instances of the ClearCollect method with the connect method.
  • B. Replace the existing code segment with the following code segment Concurrent (ClearCollect(collectNeighborList, Filter(NeighborList, Status = ג€Activeג€)), ClearCollect(collectRealtorList,CompanyList),ClearCollect(collectRegions, RegionList))
  • C. Replace the existing code segment with the following code segment: ClearCollect(collectNeighborList, Filter(NeighborList, Status = ג€Activeג€)); Concurrent(ClearCollect(collectRealtorList,CompanyList)); Concurrent(ClearCollect(collectRegions, RegionList))
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

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
itmaxuser
3 weeks, 6 days ago
Selected Answer: B
The correct solution to improve performance and resolve the issue is: B. Replace the existing code segment with the following code segment: plaintext Copy Edit Concurrent(ClearCollect(collectNeighborList, Filter(NeighborList, Status = "Active")), ClearCollect(collectRealtorList, CompanyList), ClearCollect(collectRegions, RegionList)) Explanation: Concurrent allows multiple operations to run at the same time, instead of sequentially as in the original code. This can significantly improve the app's performance when loading multiple collections. By using Concurrent, you prevent the app from waiting for one operation to complete before starting the next, which can reduce the load time and improve responsiveness.
upvoted 1 times
...
Juan0414
2 months ago
Selected Answer: B
https://learn.microsoft.com/en-us/power-platform/power-fx/reference/function-concurrent
upvoted 1 times
...
Sudheer93
7 months, 2 weeks ago
In exam - 9/23/2023
upvoted 2 times
...
MikeAWS
8 months, 1 week ago
B is correct answer. The Concurrent method is used to run multiple actions at the same time. In the existing code, all three ClearCollect methods are running sequentially. This means that the first ClearCollect method will finish running before the second ClearCollect method starts running, and so on. This can cause the app to run slowly, especially if the collections are large. The Concurrent method allows you to run multiple actions at the same time. This can help to improve the performance of your app by reducing the amount of time it takes to run all of the ClearCollect methods.
upvoted 2 times
...
shivdix
1 year, 4 months ago
B https://learn.microsoft.com/en-us/power-platform/power-fx/reference/function-concurrent
upvoted 1 times
...
gabrisca
1 year, 6 months ago
B is orrect: https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/performance-tips#optimize-the-onstart-property
upvoted 2 times
...
CoktaiiL
1 year, 6 months ago
Selected Answer: B
correct
upvoted 1 times
...
Lotsrly
1 year, 7 months ago
Selected Answer: B
Correct 100%
upvoted 4 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