Activity Forums Salesforce® Discussions Difference between List,Set And Map in Salesforce

  • PRANAV

    Member
    January 10, 2017 at 10:52 am

    Hi Vikas,

    A list is an ordered collection of elements that are distinguished by their indices. List elements can be of any data type—primitive types, collections, sObjects, user-defined types, and built-in Apex types.

    A map is a collection of key-value pairs where each unique key maps to a single value. Keys and values can be any data type—primitive types, collections, sObjects, user-defined types, and built-in Apex types.

    A set is an unordered collection of elements that do not contain any duplicates. Set elements can be of any data type—primitive types, collections, sObjects, user-defined types, and built-in Apex types.

    Yes, you can use List of list but it depends on scenario to scenario which suits best for the functionality.

    Hope this helps you.

    Thanks

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos

Salesforce Integration Tutorial | Integrate Salesforce with Apps

Video in

This "𝐒𝐚𝐥𝐞𝐬𝐟𝐨𝐫𝐜𝐞 𝐈𝐧𝐭𝐞𝐠𝐫𝐚𝐭𝐢𝐨𝐧 𝐓𝐮𝐭𝐨𝐫𝐢𝐚𝐥" video by Edureka will help you understand what is Salesforce integration in detail. It will also address the various Salesforce integration…