Toggle Side Panel

  • Blogs
  • Consultants
    • Salesforce Product Expertise
      • Top Salesforce ConsultantsTop Salesforce Consultants
      • Marketing Cloud ConsultantsMarketing Cloud Consultants
      • Service Cloud ConsultantsService Cloud Consultants
      • Experience Cloud ConsultantsExperience Cloud Consultants
      • Analytics Cloud ConsultantsAnalytics Cloud Consultants
    • Salesforce Industry Expertise
      • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
      • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
      • Health Cloud ConsultantsHealth Cloud Consultants
      • Commerce Cloud ConsultantsCommerce Cloud Consultants
      • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
    • Salesforce Experts by Location
      • USATop Salesforce Consultants in USA
      • IndiaTop Salesforce Consultants in India
      • AustraliaTop Salesforce Consultants in Australia
      • United KingdomTop Salesforce Consultants in UK
      • CanadaTop Salesforce Consultants in Canada
  • Webinars
  • Contact Us
  • Discussions
More options
    Sign in Sign up
    • Blogs
    • Consultants
      • Salesforce Product Expertise
        • Top Salesforce ConsultantsTop Salesforce Consultants
        • Marketing Cloud ConsultantsMarketing Cloud Consultants
        • Service Cloud ConsultantsService Cloud Consultants
        • Experience Cloud ConsultantsExperience Cloud Consultants
        • Analytics Cloud ConsultantsAnalytics Cloud Consultants
      • Salesforce Industry Expertise
        • Non-Profit Cloud ConsultantsNon-Profit Cloud Consultants
        • Financial Service Cloud ConsultantsFinancial Service Cloud Consultants
        • Health Cloud ConsultantsHealth Cloud Consultants
        • Commerce Cloud ConsultantsCommerce Cloud Consultants
        • Manufacturing Cloud ConsultantsManufacturing Cloud Consultants
      • Salesforce Experts by Location
        • USATop Salesforce Consultants in USA
        • IndiaTop Salesforce Consultants in India
        • AustraliaTop Salesforce Consultants in Australia
        • United KingdomTop Salesforce Consultants in UK
        • CanadaTop Salesforce Consultants in Canada
    • Webinars
    • Contact Us
    • Discussions
    Close search

    Activity › Forums › Salesforce® Discussions › What are the setup and non-setup object?

    Tagged: Account, Contact, Custom objects, Lead, Non-Setup Objects in Salesforce, Test Class

    • Salesforce® Discussions

      What are the setup and non-setup object?

      Posted by Saddam on September 11, 2019 at 2:55 PM

      What are the setup and non-setup object?

      Laveena replied 7 years, 1 month ago 4 Members · 3 Replies
      • Account
      • Contact
      • Custom objects
      • Lead
      • Non-Setup Objects in Salesforce
      • Test Class
    • 3 Replies
    • Piyush

      Member
      September 12, 2019 at 3:36 AM

      Hi Saddam,

      • Setup Object is:
        1. Profiles
        2. Users
        3. Record Type
      • Non-Setup Object :
        1. Lead
        2. Account
        2. Contact
        4. Any Custom Object
    • [adinserter block='9']
    • Nikita

      Member
      September 12, 2019 at 6:36 AM

      Hi Saddam,

      SetUp Objects:Setup objects are objects that are used to interact with the metadata. Common example is the User, Profile, Layout object.

      Non-SetUp Object: Every other objects like those which are native(Standard Objects) and Custom Objects fall into the category of Non-Setup Objects.

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

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

    • Laveena

      Member
      September 12, 2019 at 7:04 AM

      Hi Saddam,

      A "setup" object is one that must be edited from the setup or builder area of the platform.

      Setup objects are

      * User

      * RecordType

      * Profile

      etc

      and all other general objects i.e.

      * Contact

      * Account

      * Lead

      etc

      are the None setup objects.

      If you run a DML operation on setup object you can't run a DML operation on None setup object in the same context, it will show the "Mixed_DML_operation" error.

      For example, you cannot insert an account and then insert a user or a group member in a single transaction.

      Salesforce don’t allow you to run.

      Thanks

    Log In to reply.

    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me
    • Public
    • All Members
    • My Connections
    • Only Me

    Popular Salesforce Blogs

    ForceLeaderBoard - A Salesforce Trailhead & Certification Leaderboard

    Salesforce Trailhead and Certification Leader Board - ForceLeaderBoard (Unofficial)

    Blog in Others

    Force Leader Board - Salesforce Trailhead and Certification Leader Board Here it comes ... It's time to show your trailhead badges and certifications in on place.…

    Certification Leaderboard, ForceLeaderBoard, Salesforce Developers, Salesforce Trailhead, Salesforce Trailhead and Certification Leader Board
    0to1Code.Com Feb 26, 2018
    9,888  Views
    commerce cloud

    Salesforce Commerce Cloud Implementation

    Blog in Salesforce Cloud Platform

    Salesforce is a globally trusted and most popular cloud-based platform that offers a wide range of digital products to businesses to increase their potential, acquire…

    Application Server, B2B Commerce cloud, B2C Cloud Solution, B2C Commerce, B2C Commerce Application
    Cyntexa Jun 8, 2021
    7,163  Views
    lightning record

    Working and Usage of lightning:recordEditForm | Salesforce Developer Guide

    Blog in Lightning

    Build a form with the lightning:recordEditForm component to add a Salesforce record or change fields in an existing record. The part shows fields along with…

    Change Fields, Creating a Record, Customizations, data, Developer Guide
    Marziya May 28, 2021
    10,484  Views

    Popular Salesforce Videos

    Different tools use to code in APEX | APEX Basics | Salesforce Development Course

    Different tools use to code in APEX | APEX Basics | Salesforce Development Course

    Video in Salesforce Apex, Salesforce Training

    Are you aware of the tools that are used for writing codes in APEX? Here are the different tools that you can use to write…

    Salesforce Training, Salesforce Apex, salesforce, Apex, Force.com
    Prafull Jul 7, 2021
    2,816  Views
    What is Lookup Relationship in Salesforce?

    What is Lookup Relationship in Salesforce?

    Video in Salesforce Stories, Salesforce Training

    In this video, Shrey is not only teaching but also demonstrating to you "What is Lookup Relationship in Salesforce?". You will be learning: 1. How…

    Salesforce Training, Salesforce Administrator, Lookup Relationship In Salesforce, Salesforce Learning, Journey with Salesforce
    Jogender Sep 10, 2020
    1,878  Views
    Sales Cloud: Opportunity Splits in Lightning Experience

    Sales Cloud: Opportunity Splits in Lightning Experience

    Video in Lightning

    In today's connected world, technology is rapidly becoming the difference between big quarters and big misses. Companies must empower every sales rep to sell faster,…

    Salesforce Products, Salesforce Sales Cloud, Salesforce Lightning, Salesforce Lightning Experience, Salesforce Event
    Pooja Feb 8, 2018
    2,596  Views
    Footer Forcetalks logo

    support@forcetalks.com

    • twitterx

    Quick Links

    Advertise with Us

    Salesforce® Articles

    Dreamforce 2023

    Top Salesforce® Bloggers 2023

    Top Salesforce Consultants

    Get Listed

    Company

    Contact Us

    About Us

    Privacy Policy

    Terms & Conditions

    InsightHub

    Salesforce Blogs

    Salesforce Videos

    Salesforce Groups

    Salesforce Jobs

    © 2026 - Forcetalks ● All Rights Reserved

    Salesforce® is a trademark of Salesforce® Inc. No claim is made to the exclusive right to use “Salesforce”. Any services offered within the Forcetalks website/app are not sponsored or endorsed by Salesforce®.

    We use cookies to enhance your browsing experience. Please see our privacy policy if you'd like more information on our use of cookies.