Loading

Locate Reports and Dashboards Stored within Personal or Private Folders in Salesforce

Data pubblicazione: May 5, 2026
Descrizione

If you'd like to permit the location of Reports and Dashboards saved in a user's "My Personal Folder" within your SOQL query (via API version 36 or higher), follow these instructions.

Features required for this functionality

If the following features are not enabled, you'll receive an error titled "INVALID_QUERY_SCOPE" when attempting to locate reports or dashboards in private folders.

  • Ensure "Enhanced Folder Sharing " has been activated for the organization in question. NOTE: If this feature is not available, please contact Salesforce Support to have it enabled
  • Enable the "Manage All Private Reports and Dashboards" profile perm for the Profile of the user performing the search
Risoluzione

Admins can use the allPrivate SOQL scope (available via API version 36 and above) to locate reports and dashboards stored in any user's private folder. This is useful when deactivating users or auditing report storage.

Use the "allPrivate" query scope to find Reports and Dashboards in private folders

To return reports in private folders:
SELECT Id FROM Report USING SCOPE allPrivate
 
To query reports inside a specific User's private folder (replace the user ID below as appropriate):
SELECT Id FROM Report USING SCOPE allPrivate WHERE OwnerId = '005A0000000Bc2deFG'
 

To query Dynamic Dashboards that are stored within Private Folders: 
SELECT Id FROM Dashboard USING SCOPE allPrivate WHERE Type != 'SpecifiedUser'


To return the owner name or determine if a user is inactive:

1. Select "Allows SOQL Parent Relationship Queries"
2. Run the following query:

SELECT Id, Owner.Name FROM Report USING SCOPE allPrivate WHERE Owner.IsActive = false

Risorse aggiuntive

Note: When using Workbench, make sure to select Include for the "Deleted and archived records" to show Reports/Dashboards in the Recycle Bin.

- This functionality is available only for use on the Dashboards and Reports objects. It is not currently supported for use with queries against the DashboardComponent object.

- The Developer Console does not support the "allPrivate" scope, but it can be used in Workbench or Data Loader.

See Also: 
Delete a Dashboard   
Find old or inactive Reports and Dashboards to delete   
Error: "Report cannot be deleted" for report linked to dashboard component

Numero articolo Knowledge

000383270

 
Caricamento
Salesforce Help | Article