How to Query Users with Salesforce User License?

Sample SOQL:

SELECT Id, Name FROM User WHERE Profile.UserLicense.Name = 'Salesforce'


Using Report:

1. Go to Setup --> Customize --> Users --> Fields --> Create New Field.

2. Select "Formula" as the data type and "Text" as return type.

3. Use "Profile.UserLicense.Name" in the formula editor.

4. Save the formula field.

5. Use the formula field in the report.


Follow Us

Posted By : Sudeer Kamat Date :

view_module Related

  • How To Quickly Find Newly Created Fields In SalesforceHow To Quickly Find Newly Created Fields In Salesforce
  • SOQL Query to Select All Records Even From Recycle Bin in Salesforce?SOQL Query to Select All Records Even From Recycle Bin in Salesforce?
  • How to Get the List of Apex Classes from a Salesforce Org?How to Get the List of Apex Classes from a Salesforce Org?
  • SOQL Query To Get Org Wide Code Coverage in Salesforce?SOQL Query To Get Org Wide Code Coverage in Salesforce?
  • SOQL Query to Get Activity History for a Record in Salesforce?SOQL Query to Get Activity History for a Record in Salesforce?

label Labels

Comments 0