Loading
Omnistudio Document Generation
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Run the Document Generation Process Cleaner Utility in Developer Console

          Run the Document Generation Process Cleaner Utility in Developer Console

          Use the Document Generation Process Cleaner Utility to either delete the document generation process records and their associated token data content documents or only the token data content documents.

          Note
          Note If you haven't created the cleaner utility classes yet, follow the instructions in Apex Classes for Document Generation Process Cleaner Utility.
          1. Click Setup gear icon to open the quick access menu, and then select Developer Console.
          2. From the Debug menu, select Open Execute Anonymous Window.
          3. Copy one of the statements in the Enter Apex Code dialog and specify the start and end times.
            1. To call cleanDocumentGenerationProcessAndContentDocument:
              DocumentGenerationProcessCleanerUtility obj = new DocumentGenerationProcessCleanerUtility();
              DateTime starttime= DateTime.newInstanceGmt(2022,11,08,18,49,48);
              DateTime endtime= DateTime.newInstanceGmt(2022,11,09,01,20,48);
              obj.cleanDocumentGenerationProcessAndContentDocument(starttime,endtime);
              
            2. To call cleanContentDocument use:
              DocumentGenerationProcessCleanerUtility obj = new DocumentGenerationProcessCleanerUtility();
              DateTime starttime= DateTime.newInstanceGmt(2022,11,08,18,49,48);
              DateTime endtime= DateTime.newInstanceGmt(2022,11,09,01,20,48);
              obj.cleanContentDocument(starttime,endtime);
          4. Select the statement you pasted.
          5. Click Execute Highlighted.
            You can view the batch job ID and the count of successfully deleted records in the log files.
          6. Close the Developer Console.
           
          Loading
          Salesforce Help | Article