1

Using the API, I am unable to move/copy the reports in the system folder 'Public Report' en masse. In workbench I find all folders except the 'Public Folder', can anyone help me?

2
  • 1
    Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. Commented Mar 14, 2022 at 17:21
  • 1
    The Unfiled Public Reports folder API name is unfiled$public Commented Mar 16, 2022 at 4:02

1 Answer 1

1

Following the guidance listed here: Bulk Move Reports or Dashboards with Metadata API

Identify your scope of reports and include the DeveloperName of the report in the extract. You can do this with the DataLoader. Once you have the information, wrap it in a member tag using a formula to build the path to the report:

=concat("<members>unfiled$public/",report_cell,"</members>") 

screenshot of formula in excel

From there you can paste it into a package.xml

<?xml version="1.0" encoding="UTF-8"?> <Package xmlns="http://soap.sforce.com/2006/04/metadata"> <types> --paste here-- <name>Report</name> </types> <version>61.0</version> </Package> 
  1. Retrieve the package.xml. You can use a command like sf project retrieve start --manifest customPackage.xml --target-org yourOrgAlias

  2. Once the information has pulled down, rename the containing folder of the report metadata from "unfiled$public" to the API name of your new folder.

  3. Update your package.xml to use the API name of the new folder instead of the unfiled$public report. before folder rename

    after folder rename

  4. Then deploy with the new package.xml and metadata structure.

<?xml version="1.0" encoding="UTF-8"?> <Package xmlns="http://soap.sforce.com/2006/04/metadata"> <types> <members>renamedFolder/View_Campaign_Influence_Report</members> <name>Report</name> </types> <version>61.0</version> </Package> 

This will move all of the reports from the public folder to the renamedFolder. Thankfully, updating the xml of the actual report data is not required.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.