We've moved to Scorecard 2.0 and no longer need the data in the UsageData object. In order to get rid of that data, we have to use DataLoader and hard delete. That's do-able, but time consuming.
I tried using Truncate, but it's not an option for custom objects in managed packages.
I'd like a tool to remove all data from UsageData so I don't have to do that manually.
Hi,
You want to delete all records and make UsageData object empty or just the scorecard measure in UsageData empty ?
Thanks
You want to delete all records and make UsageData object empty or just the scorecard measure in UsageData empty ?
Thanks
If you have access to Developer console then you can run this Apex code.
delete [SELECT Id from JBCXM__UsageData__c];
**** IMPORTANT ****
This deletes every thing in UsageData permanently.
***** Please use caution *****
Thanks 🙂
delete [SELECT Id from JBCXM__UsageData__c];
**** IMPORTANT ****
This deletes every thing in UsageData permanently.
***** Please use caution *****
Thanks 🙂
Yep this will work, however you'll need to add a LIMIT 10000 clause as SFDC only allows 10k records to be deleted at a time.
Amber what I'd do is use workbench to export all records (choose bulk csv option) from the Usage Data object. You can then run a delete job directly from Workbench using SFDC's Bulk API which batches them for you in 10k jobs.
All you'll need to do is map the Id in the file to Id in the delete option. If you have any questions, please let me know.
All you'll need to do is map the Id in the file to Id in the delete option. If you have any questions, please let me know.
Reply
Login to the community
Enter your username or e-mail address. We'll send you an e-mail with instructions to reset your password.