Free Salesforce PDI Exam Braindumps (page: 15)

A Platform Developer needs to write an Apex method that will only perform an action if a record is assigned to a specific Record Type.
Which two options allow the developer to dynamically determine the ID of the required Record Type by its name? (Choose two.)

  1. Make an outbound web services call to the SOAP API.
  2. Hardcode the ID as a constant in an Apex class.
  3. Use the getRecordTypeInfosByName() method in the DescribeSObjectResult class.
  4. Execute a SOQL query on the RecordType object.

Answer(s): C,D



Given:
Map<ID, Account> accountMap = new Map>ID, Account> ([SELECT Id, Name FROM Account]);
What are three valid Apex loop structures for iterating through items in the collection? (Choose three.)

  1. for (ID accountID : accountMap.keySet()) {...}
  2. for (Account accountRecord : accountMap.values()) {...}
  3. for (Integer i=0; I < accountMap.size(); i++) {...}
  4. for (ID accountID : accountMap) {...}
  5. for (Account accountRecord : accountMap.keySet()) {...}

Answer(s): A,B,C



A developer is asked to set a picklist field to `Monitor' on any new Leads owned by a subnet of Users.
How should the developer implement this request?

  1. Create an after insert Lead trigger.
  2. Create a before insert Lead trigger.
  3. Create a Lead Workflow Rule Field Update.
  4. Create a Lead formula field.

Answer(s): C



When is an Apex Trigger required instead of a Process Builder Process?

  1. When a record needs to be created
  2. When multiple records related to the triggering record need to be updated
  3. When a post to Chatter needs to be created
  4. When an action needs to be taken on a delete or undelete, or before a DML operation is executed.

Answer(s): D






Post your Comments and Discuss Salesforce PDI exam prep with other Community members:

PDI Exam Discussions & Posts