Search This Blog

Saturday, December 5, 2015

Salesforce Interview Questions

1) What is the advantage of using custom setting?
Ans:You donot have to query in apex(fire select query) to retrieve the data stored in custom settings.
2) what is whoid and whatid in activities?
Ans:Whoid is the id of either contact or lead.Whatid is the id of the related to record in activiity record(standard or custom object).
3) what is the difference between  a standard controller and custom controller?
standard controller inherits all the standard object properties,standard button functionalities can be directly used.Custom controller defines custom functionalities,a standard controller can be extended to develop custom functionalities using keyword "extensions".
4) Can you have more than one extension associated with a single page?
Ans:Yes we can have more than one extension.
5) If page is having extensions and if two extensions have methods of same name.Then which method out of these two will be called from vf page?
Ans:The one which is present in the controller defined on the left side will be called.
6) What are governer limits?
Ans:Governer limits are the limits impossed by salesforce so as to avoid monopoly by orgs in using salesforce shared resources.
7) What is the difference between force.com and salesforce.com?
Ans:force.com is paas(platform as a service) and salesforce.com is Saas(Software as a service)
8) How many records can a select query return?
Ans:As of now,it can return upto 50000 records.
9) How many records can a sosl query return?
Ans:As of now it can return upto 2000 records.
10) How can you access custom label in visualforce page?
Ans:Use this syntax for accessing custom label in visualforce page - {!Label.LabelName} where LabelName is the name of Label.
11) How can you query all records(including deleted records) using an SOQL query?
Ans:Using ALL Rows Keyword.This will query all records including deleted records in recyclebin.
Eg:List <Account> accountList = [select id from account  ALL ROWS];
12) What is the use of @future annotation?
Ans: Using @future annotation with a method executes it whenever salesforce has resources available.
13) what is the significance of static keyword?
Ans:Methods,variables when defined as static are initialized only once when class is loaded.Static variables are not transmitted as part of view state for a visualforce page
14) Can custom setting be accessed in a test class?
Ans:Custom setting data is not available default in a test class.We have to set seeAllData parameter true while defining a test class as below
@isTest(seeAlldata=true).
15) what is the difference between role and profile?
Ans:Role defines record level access while profile defines object level access.
16) what is the maximum file size for a generated  PDF file?
Ans:The maximum file size for a generated PDF file is 60 MB.
Visualforce PDF Rendering Considerations and Limitations:Go through the below link
https://developer.salesforce.com/docs/atlas.en-us.pages.meta/pages/pages_output_pdf_considerations.htm

No comments:

Post a Comment