nerdexam
Salesforce

PDII · Question #202

A managed package uses a list of country ISO codes and country names as reference data in many different places from within the managed package Apex code. What is the optimal way to store and…

The correct answer is D. Store the information in Custom Metadata and access it with the getAll() method. See the full explanation below for the reasoning.

Question

A managed package uses a list of country ISO codes and country names as reference data in many different places from within the managed package Apex code. What is the optimal way to store and retrieve the list?

Options

  • AStore the information in Custom Metadata and query it with SOQL
  • BStore the information in a List Custom Setting and access it with the getAll() method
  • CStore the information in a List Custom Setting and query it with SOQL
  • DStore the information in Custom Metadata and access it with the getAll() method

How the community answered

(25 responses)
  • A
    16% (4)
  • B
    8% (2)
  • C
    4% (1)
  • D
    72% (18)

Community Discussion

No community discussion yet for this question.

Full PDII Practice