16. How can you call a controller method from java script ?
Ans: Use action function component to call controller method from java script.
Ans: Use action function component to call controller method from java script.
17. How can you call a visualforce page from a controller method?
Ans: Use pagereference object for calling a visualforce page from controller method
Ans: Use pagereference object for calling a visualforce page from controller method
18. How can you sort a select SOQl query ?
Ans: use order by clause in select query for sorting a list of records
Ans: use order by clause in select query for sorting a list of records
19. How much code coverage is needed for deployment?
Ans : Each trigger should have minimum of 1%. Class can have 0%. But, the total code covergae of 75%.
Ans : Each trigger should have minimum of 1%. Class can have 0%. But, the total code covergae of 75%.
20. Can 'set' store duplicate values in it?
Ans : No. Set only stores unique values. List can have duplicate values in it.
Ans : No. Set only stores unique values. List can have duplicate values in it.
21. Can two users have same profiles?
Ans: Yes
Ans: Yes
22. How can you refresh a particular section of a visualforce page?
Ans: This can be done using reRender attribute
Ans: This can be done using reRender attribute
23. How can you create a many to many relationship in salesforce
Ans: This can be done by creating junction object between the two objects.
Ans: This can be done by creating junction object between the two objects.
24. What happens to detail record when a master record is deleted?
Ans: detail record gets deleted.
Ans: detail record gets deleted.
25. What happens to child record when a parent record is deleted(look up relationship)?
Ans. Child record remains undeleted
Ans. Child record remains undeleted
26. How to get current logged in users id in apex ?
Ans: Use Userinfo.getuserid() to get the current logged in user's id in apex.
Ans: Use Userinfo.getuserid() to get the current logged in user's id in apex.
27. How to convert a csv file browsed in visualforce page into a string.
Ans: use csvfilecontents.tostring(). method to convert blob to string
Ans: use csvfilecontents.tostring(). method to convert blob to string
28.How many records can a select query return ?
Ans : As of now it can return upto 50000 records.
Ans : As of now it can return upto 50000 records.
29. How many records can a sosl query return ?
Ans: as of now it can return upto 2000 records
Ans: as of now it can return upto 2000 records
30. How to fire dynamic query in soql?
Ans: Using database.queryExample: List<account> accList = Database.query('select name from account');
Ans: Using database.queryExample: List<account> accList = Database.query('select name from account');
No comments:
Post a Comment