How to delete data from Kusto table

Sujatha Erepalli (Brillio LLC) 20 Reputation points Microsoft Vendor

I'm trying to use the .delete command instead of purge to remove data from a table. As, .delete does not change the ingestion timestamp, or the tags created and helps to restate the data when needed.

The .delete command performs a soft delete, making the data logically inaccessible and irreversible, but it does not immediately delete the storage artifacts. Also, the rows marked as deleted are eventually purged.

I have questions about the retention policy in this context. Is the retention policy at the database level the same as the policy for. delete, or are they different? For example, if the retention policy for soft deletes in the database is set to unlimited, does this mean the rows deleted with. delete also have an unlimited retention period, or are they completely purged after 14 days?

If. delete is not the right function for permanently deleting records, what is the best way to ensure that any data is fully removed from the system?

Azure Data Explorer
Azure Data Explorer
An Azure data analytics service for real-time analysis on large volumes of data streaming from sources including applications, websites, and internet of things devices.
500 questions
{count} votes

Accepted answer
  1. Sander van de Velde | MVP 30,556 Reputation points MVP

    Hello @Sujatha Erepalli (Brillio LLC) ,

    welcome to this moderated Azure community forum.

    It's not clear to me what 'PII' data is but in general the same deletion flow is applicable to all tables.

    Please check the documentation regarding the soft delete policy object.

    Soft deleted data is recoverable for a limited period:

    If set to Enabled, the data will be recoverable for 14 days after it's been soft-deleted.

    The SoftDeletePeriod defaults to '100 years' but it's related to the retention time of the table which is normally tied to the database retention time.

    You can check the retention time yourself eg.:

    .show table Table1 policy retention

    The documentation also comes with several examples.

    If the response helped, do "Accept Answer". If it doesn't work, please let us know the progress. All community members with similar issues will benefit by doing so. Your contribution is highly appreciated.

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful