nerdexam
Salesforce

PDII · Question #74

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…

The correct answer is C. Filter the Debug Log on SOQL_EXECUTE_END statements to track the results of each SOQL. See the full explanation below for the reasoning.

Question

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?

Options

  • ACount the number of Row Limit warning messages in the Debug Logs
  • BAdd System.debug(System.getQueryRows()) to the code to track SOQL usage
  • CFilter the Debug Log on SOQL_EXECUTE_END statements to track the results of each SOQL
  • DUse the Execution Overview to see the number of rows returned by each Executed Unit

How the community answered

(52 responses)
  • A
    6% (3)
  • B
    2% (1)
  • C
    81% (42)
  • D
    12% (6)

Community Discussion

No community discussion yet for this question.

Full PDII Practice