Best approach as per industry standards for data cleansing

  • Hi Experts,

    I have a database with more than 600+ tables. Some of the table are very big ranging from 50 to 60 GB in production. Tables are related to each other using foreign key (no ON DELETE CASCADE). I have been asked to remove data from all these tables where PCode=10. Most of the tables have multiple indexes on it. I know, inner join delete operations, are going to be extremely resource intensive especially on our bigger tables. Guys, please do let me know what is the best practical approach (as per industry standards) to remove these data from all the table at the least possible time.

    Thanks in advance.

    Regards,

    Naveen

  • You can delete the data by committing small chunk of the data which will help tlog file to grow minimal with very minimal open transactions.

    Usually after large insert/delete operation SQL Server update statistics. However if it won't do it, you can do it manually to ensure good performance of the query. You can also plan for reindexing.

    You can also export table data before deleting records and keep the backup for future reference; in case anyone might required.

    HTH

    ---------------------------------------------------
    "Thare are only 10 types of people in the world:
    Those who understand binary, and those who don't."

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply