Take the 2-minute tour ×
Salesforce Stack Exchange is a question and answer site for Salesforce administrators, implementation experts, developers and anybody in-between. It's 100% free, no registration required.

I am trying to find out the available record types for each object for an entire profile.

Is this possible to do?

I would like to compare who has access to record types.

share|improve this question

3 Answers 3

Yes, and there are a few ways of doing this.

  1. Go through the UI, object-by-object. Not recommended.
  2. Use the Force.com Migration Tool. This will allow you to download the profiles as XML and you can examine them that way.
  3. Get the profile XML via a Change Set. This is similar to option 2, but doesn't require command-line tools that might be intimidating. To do this you would create a Change Set with the profile(s) in question and upload it to a different org. When you view the Inbound Change Set there will be a "View Source" link next to each item; this will show you the Metadata XML for the object. You do not have to deploy the Change Set, just upload it.

When examining the XML there will be a section for record types, similar to the following:

<recordTypeVisibilities>
 <default>true</default>
   <recordTypes>MyObject.NewDefaultType</recordTypes>
   <visible>true</visibles>
</recordTypeVisibilites>

Just look at the part for <visible>.

share|improve this answer

This information would be available via the Metadata API. So You could pull down the Profile Metadata XML files via the Force.com IDE and when you've got the Profile Xmls, you can interrogate these files to find the recordTypeVisibilities elements

recordTypeVisibilities    
Indicates the  visibility of record types for users assigned to this profile.

http://www.salesforce.com/us/developer/docs/api_meta/Content/meta_profile.htm

As an aside, users would be able to see records with all record types so long as they have Read Access to the Record. The explicit RecordType permissions only determine which RecordTypes the user can create records of, if they have Create Access on the Object.

share|improve this answer

Check out the answer to the Compare Profiles question on the stackexchange: http://salesforce.stackexchange.com/a/3693/220

The easiest way I know to do this is to use the force.com eclipse IDE where you can easily declare that you want all custom objects and profiles which will return the junction or intersection of profile settings including record types.

To help eliminate any eclipse specific behaviors, I typically create a package.xml file with the following text/elements:

<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
    <types>
        <members>*</members>
        <name>CustomObject</name>
    </types>
    <types>
        <members>*</members>
        <name>Profile</name>
    </types>
    <version>26.0</version>
</Package>

Then I retrieve it using the workbench tool: http://workbench.developerforce.com by going to the migrate >> retrieve menu setting (I select single package when retrieving to be safe).

The resulting zip file will contain all of your profile settings including record type settings.

Hope this helps.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.