Toggle Side Panel

  • Home
  • Articles
    • All Articles
    • Blogs
    • Videos
    • Infographics
  • 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
  • Marketplace
  • Advertise With Us
  • Contact Us
  • Discussions
More options
    Sign in Sign up
    • Home
    • Articles
      • All Articles
      • Blogs
      • Videos
      • Infographics
    • 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
    • Marketplace
    • Advertise With Us
    • Contact Us
    • Discussions
    Close search

    Activity › Forums › Salesforce® Discussions › How to get values stored in custom metadata type object in Salesforce Apex?

    Tagged: Apex Component, Custom Metadata Loader, Custom Metadata Type, Get Values in Salesforce, Salesforce Apex Class

    • Salesforce® Discussions

      How to get values stored in custom metadata type object in Salesforce Apex?

      Posted by kapil on March 19, 2018 at 10:05 AM

      how to get values stored in custom metadata type object in apex?

      Parul replied 7 years, 6 months ago 3 Members · 2 Replies
      • Apex Component
      • Custom Metadata Loader
      • Custom Metadata Type
      • Get Values in Salesforce
      • Salesforce Apex Class
    • 2 Replies
    • PRANAV

      Member
      March 19, 2018 at 10:55 AM

      Hi Kapil,

      The Custom Metadata Type has a suffix of __mdt instead of __c (for Custom objects/fields).

      Custom metadata type field names have a suffix of __c, like other custom fields.

      You can do query like this

      SELECT Entity_Relationship__c, Field_Relationship__c, Default__c FROM Source_Default_Value__mdt WHERE Entity_Relationship__c = 'Account'

      For more you can refer to the standard salesforce guide "Custom Metadata Types
      Implementation Guide" and practise this on Trailhead "Custom Metadata Types".

      Hope this helps you.

    • Parul

      Member
      September 18, 2018 at 8:03 PM

      Hi

      You can do query like this

      SELECT Entity_Relationship__c, Field_Relationship__c, Default__c FROM Source_Default_Value__mdt WHERE Entity_Relationship__c = ‘Account’.

       

      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

    application solution

    Popular Salesforce Blogs

    How to connect C# to Salesforce via ADO.NET

    Blog in Salesforce Data integration

    Salesforce data is critical, but integrating it cleanly into C# applications is rarely straightforward. REST-based approaches often introduce fragmented authentication logic, brittle mappings, and operational overhead that…

    Tim Feb 27, 2026
    220  Views

    Automation Hero | Salesforce Process Builder a step ahead Workflow

    Blog in Salesforce Ecosystem

    Every day at our workplace, we spend a considerable amount of time doing routine work processes that mostly repetitive and do not require any special…

    Process Builder, Process Triggers, Salesforce Automation, Salesforce Development, Salesforce Ecosystem
    LevelShift (formerly DemandBlue) Oct 25, 2019
    4,785  Views

    Benefits of Hiring Salesforce Managed Services: Things to know

    Blog in Others

    There is no doubt that Salesforce is one of the most powerful and versatile business tools currently available. Salesforce provides many benefits, such as streamlining…

    vishal Aug 1, 2025
    144  Views

    Popular Salesforce Videos

    TOP 20 Salesforce Integration Interview Questions and Answers 2019 | Salesforce Integration

    TOP 20 Salesforce Integration Interview Questions and Answers 2019 | Salesforce Integration

    Video in Salesforce Integration

    In this video, Wisdom Jobs and Tutorials explains the 20 most popular questions asked during Salesforce Integration interviews. These questions cover topics like what web…

    Salesforce Training, Salesforce Tutorial, Salesforce Jobs, Salesforce Integration, salesforce
    Mayra Jan 12, 2023
    1,387  Views
    What is Approval Process in Salesforce?

    What is Approval Process in Salesforce?

    Video in Salesforce Admin

    Automated process that approves records for the organization and it can be defined with a sequence of steps. Watch the video to learn and if…

    Salesforce Training, Salesforce Online Training, Salesforce Objects, Salesforce Org, Salesforce Approval process
    CRS May 4, 2022
    1,795  Views
    Salesforce For Non Programmers | Salesforce For Non Technicals

    Salesforce For Non Programmers | Salesforce For Non Technicals

    Video in Salesforce Training

    You can learn Salesforce without any programming language. You can plan Salesforce Administrator Certification which requires no coding skills. Watch this video to learn how.

    Salesforce Training, Salesforce Tutorial, Salesforce Certification, salesforce, Salesforce Video
    Jogender Jan 21, 2022
    4,328  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®.

    Try AuditMyCRM - It is a Salesforce CRM Audit tool which comprehensively scans your Salesforce org and gives you the list of errors or warnings you need to take care of.
    We use cookies to enhance your browsing experience. Please see our privacy policy if you'd like more information on our use of cookies.