user3845056
user3845056

Reputation: 497

CRM Dynamics 2015 Bulk Delete, delete all data from insance

I am wondering if anyone has performed bulk deletes to clear all data out of a CRM environment? My plan was to create a console app that performed a number of Bulk Deletes. But my initial testing found this to be very slow.

I am asking because we are doing data migration form an existing .NET system to CRM. I want to clear all the data from CRM so we can re run and re test the data migration component.

Has any one got any suggestions?

F.Y.I this is using CRM Dynamics Online

Upvotes: 3

Views: 1724

Answers (3)

Alessi
Alessi

Reputation: 769

Another way would be to create non production instances and do your test runs there. You can then refresh the non prod instance with a copy of prod for the succeeding test cycles. The time to reset your target organisation will be close to constant, unless your production data increases rapidly. (i.e. heavy transactions).

This is even better if you're CRM is not yet live, I read from your post that you wanted to remove all records in CRM.

Upvotes: 0

Shane
Shane

Reputation: 790

IOrganizationService.Delete() will simply be faster - but not better. Remember that simply removing a record might leave related records unusable and using the SDK does not do the checks that the bulk delete will do for you. My findings are that using the bulk delete gives you the assurance of proper data that are left behind and will follow design and prompt when something aren't allowed or cannot get deleted till something else is not removed first.

My suggestion (in your case) . start by running the bulk delete on all parent records, once cleared move on the relateds.

Upvotes: 0

Alessi
Alessi

Reputation: 769

From experience I find that calling the IOrganizationService.Delete () method from an external application is faster than using the BulkDelete operation.

Upvotes: 1

Related Questions