sai venkat prakash
sai venkat prakash

Reputation: 31

How can i get all the approval process names for a specific object in salesforce

i have to write a query to get all the approval processes on a specific xyz__c custom object

select Name from ProcessDefinition

the above query display all objects approval processes .but i need specific approval process on a particular object

Upvotes: 1

Views: 2809

Answers (1)

David Reed
David Reed

Reputation: 2759

The TableEnumOrId field is the one you need to query:

Specifies the object associated with the approval process, such as Account or Contact.

Hence

SELECT Id, TableEnumOrId FROM ProcessDefinition

Upvotes: 2

Related Questions