Best way of deleting data in CRM 2011? RRS feed

  • Question

  • Hi All,

    What will be best approach to delete data in CRM 2011. Approach should be applicable for multiple entities and multiple times we need to perform delete activity. 

    Tried with out of box Bulk delete functionality but it is causing slow performance. Not looking for this option.

    Will Windows service help?

    Please suggest.



    Tuesday, November 24, 2015 3:49 PM

All replies

  • What is the performance problem with using the Bulk Delete ? Is it:

    1. It slows the rest of the system down when running the delete
    2. The delete process takes a long time to execute
    3. The delete process runs asynchronously, and it can be a delay before it starts

    It's unlikely that you can write a process that can delete CRM data in a supported way that is more efficient than the bulk delete, so if your issue is number 1 or 2, then there's not much you can do about it (other than unsupported direct SQL deletes, which is potentially very dangerous). If your issue is a delay before the process starts, then that is probably because of a backlog of work for the asynchronous service

    Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk

    Wednesday, November 25, 2015 10:09 AM
  • Hi, Thanks for reply.

    My issue is number 3. The delete process runs asynchronously, and it can be a delay before it starts

    This is the reason I am trying to avoid Bulk delete. I understand the Bulk Delete is very powerful and most useful functionality of CRM but in my case I need to look for other option.


    Wednesday, November 25, 2015 10:44 AM
  • Hi Anand,

    If you want to delete stuff en masse you could write a program that does that for you. If you use executemultiple and threading you can get decent throughput. The issue will probably be how to select what you want to delete and how you want to push that info to the program.


    Rickard Norström Developer CRM-Konsulterna
    Swedish Dynamics CRM Forum: http://www.crmforum.se
    My Blog: http://rickardnorstrom.blogspot.se

    • Proposed as answer by Raman Agarwal Friday, December 11, 2015 10:50 PM
    Wednesday, November 25, 2015 1:54 PM
  • Thank you David and Rickard. Yes I will go with program using threading.


    Friday, November 27, 2015 9:39 AM