exam questions

Exam Certified Platform Developer II All Questions

View all questions & answers for the Certified Platform Developer II exam

Exam Certified Platform Developer II topic 1 question 93 discussion

Actual exam question from Salesforce's Certified Platform Developer II
Question #: 93
Topic #: 1
[All Certified Platform Developer II Questions]

A developer receives a LimitException: Too many query rows: 50001 error when running code.
What debugging approach using the Developer Console provides the fastest and most accurate mechanism to identify a specific component that may be returning an unexpected number of rows?

  • A. Count the number of Row Limit warning messages in the Debug Logs
  • B. Add System.debug(System.getQueryRows()) to the code to track SOQL usage
  • C. Filter the Debug Log on SOQL_EXECUTE_END statements to track the results of each SOQL Query
  • D. Use the Execution Overview to see the number of rows returned by each Executed Unit
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

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
beardAnt
2 months, 4 weeks ago
Selected Answer: D
the Execution Overview actually provides the exact query , filter by SOQL_EXECUTE_END just gives you the number of rows, but not the query itself, that is in SOQL_EXECUTE_BEGIN Event
upvoted 1 times
...
FriedConsole2000
10 months, 2 weeks ago
Selected Answer: C
"C". You want to find the SOQL that is causing the problem so you have to look at each SOQL and see they number it returns.
upvoted 1 times
...
Segre
1 year, 9 months ago
Selected Answer: D
Definitely D, the limit is cumulative across all the SOQL queries in the transaction. So jumping from each SOQL invocation from the raw log view could take a while till you understand the whole picture which led to 50000+ records being queried.
upvoted 1 times
...
ejh
1 year, 9 months ago
Selected Answer: D
D is better as the number if Rows is displayed in the limits tab of the Execution Overview
upvoted 1 times
...
lorenac2
1 year, 11 months ago
Selected Answer: C
If the question was slightly altered to say specific 'query' instead of 'component', then yes I believe C is correct. SOQL_EXECUTE_END > "Line number, number of rows, and duration in milliseconds" https://developer.salesforce.com/docs/atlas.en-us.apexcode.meta/apexcode/apex_debugging_system_log_console.htm
upvoted 2 times
...
Peter808
2 years, 3 months ago
I have some doubts how to consider this D because: An execution unit is equivalent to a transaction. It contains everything that occurred within the transaction. EXECUTION_STARTED and EXECUTION_FINISHED delimit an execution unit. Maybe the most accurate still C?
upvoted 1 times
...
nibbio
3 years ago
Use the Limit Panel of Execution Overview
upvoted 2 times
OmShantiVeg
2 years, 5 months ago
Yes maybe D is better
upvoted 1 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