Activity Forums Salesforce® Discussions What are setup objects in Salesforce?

  • saloni gupta

    Member
    August 1, 2017 at 1:04 pm

    hi shariq,

    Setup objects are those which interacts with metadata like User, Profile, Layout etc. All other object (Standard and Custom) are non setup object.

    One important note is that we cannot perform DMLs on setup and non setup objects in same transaction. Workaround is that you need to use asynchronous requests (@future) or use batch as it runs in its own system context.

    In test class you can use Sytem.RunAs with two different users to separate out transactions for setup and non setup objects.

  • Archit

    Member
    January 11, 2018 at 3:04 am

    Hello Shariq,

    For setup objects

    • These objects only works for metadata, a very common example is User object. We use setup objects to interact with metadata for declarative development.
    • Represents a data service that adds and updates data in existing records in an org.

    Hope this answer would be helpful!!

  • Parul

    Member
    September 15, 2018 at 2:45 pm

    The setup objects in Salesforce are objects that work for metadata like User and Profile and on setup object we can not perform DML operation.

     

     

    Thanks

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos