PrepAway - Latest Free Exam Questions & Answers

In which two ways can the developer retrieve the available fields if the variable myObject represents the name

A developer needs to display all of the available fields for an object.

In which two ways can the developer retrieve the available fields if the variable myObject represents the name of the object? Choose 2 answers.

A. Use myObject.sObjectType.getDescribe ().fieldSet () to return a set of fields.

B. Use SObjectType.myObject.fields.getMap() to return a map of fields.

C. Use getGlobalDescribe().get(myObject).getDescribe().fields.getMap() to return a map of fields.

D. Use Schema.describeSObjects (new String[] {myObject}) [0].fields.getMap () to return a map of fields.


Leave a Reply