Sunday 6 December 2020

How to delete debug logs in Salesforce

 Different ways to delete Debug Logs:



Using tooling API Query

1. Log in to your Org as an admin user.
2. Open the developer console by clicking on the gear icon on the top right.
3. Open query editor and run the below query

SELECT Id, StartTime, LogLength FROM ApexLog

4. Enable 'Use tooling API' and click on the execute button. 
5. You will get the list of all debug log records.
6. Select the rows you want to delete using the Ctrl or Shift and arrow keys.
7. Click on the 'Delete Row' button to get them deleted.






In SFDX:

Use the below method to delete debug logs from the terminal:

$ sfdx force:data:soql:query -q "SELECT Id FROM ApexLog" -r "csv" > out.csv $ sfdx force:data:bulk:delete -s ApexLog -f out.csv


No comments:

Post a Comment

How to generate QR code for Survey Invitation in Salesforce Platform Survey

 Easy steps to generate QR code for Survey Invitation Link 1) Create your Survey using Salesforce Platform Survey. 2) Once done activate it....