How to get the list of record type Id of an sObject by SOQL

  • I am looking for a SOQL query to get the list of record type Id for a given sObject Name

  • benahm

    benahm Correct answer

    4 years ago

    By querying the recordType object and filtering by the sObjectType

    select Id,Name from RecordType where sObjectType='Account'

    It takes a minute for you to post a question and 2 for finding the answer. In that case I suggest you should do more research. Still good to see that you are able to answer your own question :)

    @RahulSharma I'm just sharing some knowledge here, I am following this stack recommendation => ;)

    Ah thanks for the clarification, it was not clear from your question and answer.

License under CC-BY-SA with attribution

Content dated before 7/24/2021 11:53 AM

Tags used