Question 11

What must the Controller for a Visulforce page utilized to override the standard Opportunity view button?
  • Question 12

    In which order does Salesforce execute events upon saving a record?
  • Question 13

    A developer wrote a unit test to confirm that a custom exception works properly in a custom controller, but the test failed due to an exception being thrown. What step should the developer take to resolve the issue and properly test the exception?
  • Question 14

    A developer uses a before insert trigger on the Lead object to fetch the Territory__c object, where the Territory__c.PostalCode__c matches the Lead.PostalCode. The code fails when the developer uses the Apex Data Loader to insert 10,000 Lead records. The developer has the following code block: Line-01: for (Lead l : Trigger.new){Line-02: if (l.PostalCode != null) {Line-03: List<Territory__c> terrList = [SELECT Id FROM Territory__c WHERE PostalCode__c = :l.PostalCode];Line-04: if(terrList.size() > 0) Line-05: l.Territory__c = terrList[0].Id; Line-06: }Line-07: }Which line of code is causing the code block to fail?
  • Question 15

    A developer uses an 'after update' trigger on the Account object to update all the Contacts related to the Account. The trigger code shown below is randomly failing.
    List<Contacts> theContacts = new List<Contacts>(); for(Account a : Trigger.new){ for(Contact c : [SELECT Id, Account_Date__c FROM Contact WHERE AccountId = :a.Id]){ c.Account_Date__c = Date.today(); theContacts.add(c);
    }
    } updates theContacts;
    Which line of code is causing the code block to fail?