salesforce interview questions and answers 4

Part 1 (1-15) - Part 2 (16 -30) - Part 3 (31 -45) - Part 4 (46 -55) - Part 5 (56 -66) - Part 6 (67 - 78) - Part 7 (79 - 90) - Part 8 (91 - 100) - Part 9 (101- 111) - Part 10 (112 - 120) - Part 11 (121 - 130) - Part 12 (131 - 137) - Part 13(138 - 145) - Part 14 (146 - 152) - Part 15 ( 153 - 159) - Part 16 ( 160 - 168) Part 19 (188 - 201)
46. How to embed a visaulflow in a visualforce page ?
Ans: Use this syntex to embed flow in vf page : <flow:interview />
47. How to enable inline editing in visauflorce page ?
Ans You can enable inline editing in visualforce page by using <apex:inlineEditSupport> component.
48. What is trigger.new in trigger ?
Ans: trigger.new is a list of records that are in the context of trigger or becuase of these records(modification,Creation, deletion) the trigger has been called
49. How do we bulkify the trigger ?
Ans: Bulkfification requires iterating over all the records in trigger context
     for example : for(account ac: trigger.new){
                       // your logic here           
                   }
50.How can we get the old value in trigger ?
Ans: use trigger.old map for getting previous values of fields.
51. Can we modify records directly in trigger.new ?
Ans: trigger.new is a read only list, but field values can be changed in case of before trigger
52. What does the error "list has no rows for assignment" mean?
Ans: it means the list you are trying to access has no values in it.
53. Why should we not write select query within for loop?
Ans: Writing select query within for loop may hit the governer limit of 100 select queries.
54. What should we do to avoid view state error in visualforce page?
Ans: Clear unused collections, define variable as transient.
55. What is a sandbox org?
Ans: It is the exact copy of your production org.
Part 1 (1-15) - Part 2 (16 -30) - Part 3 (31 -45) - Part 4 (46 -55) - Part 5 (56 -66) - Part 6 (67 - 78) - Part 7 (79 - 90) - Part 8 (91 - 100) - Part 9 (101- 111) - Part 10 (112 - 120) - Part 11 (121 - 130) - Part 12 (131 - 137) - Part 13(138 - 145) - Part 14 (146 - 152) - Part 15 ( 153 - 159) - Part 16 ( 160 - 168) Part 19 (188 - 201)

No comments:

Post a Comment