Base solution for your next web application
Open Closed

Best way to Delete a Tenant? #4210


User avatar
0
OutdoorEd created

I have a SaaS application that contains sensitive client data. If the client ever decides to cancel their contract I need to remove all of their data. To test this out in pre-production I have created a Cascade Delete from AbpTenant to the Client's data so that deleting a Tenant in AbpTenant from SSMS removes all the Client's data. It does leave the Tenant in all of the other Abp Tables (since it is a soft delete). What is the best way to remove all the other references to that Tenant? I don't want to disable the Tenant Soft Delete. Should this just be a SQL script I need to generate?

Markdown is supported
Copy & paste or drag & drop images (max 30 MB per image)

1 Answer(s)
  • User Avatar
    0
    aaron created
    Support Team
    1. You need to cascade soft deletes yourself.
    2. There is no way to hard-delete ISoftDelete entities.

    What is the best way to remove all the other references to that Tenant? Should this just be a SQL script I need to generate?

    Yes, you answered your own question with another question :)

    Markdown is supported
    Copy & paste or drag & drop images (max 30 MB per image)