Reputation: 544
I'm trying to delete historical data from DELTA using the VACUUM command but it doesn't do anything
I ran the DRYRUN command to show which files have to be deleted, but nothing comes back, but looking at the JSON file in the delta folder is already in time to erase the data.
I ran this command to delete data, but without success, and analyzing the JSON timestamp it would be in the delete time. Am I doing something wrong?
%sql
delta VACUUM.`/mnt/deltaTestVacuum/myTable/`
Json with timestamp remove inside in directory _delta_log
Upvotes: 2
Views: 3792
Reputation: 11
What is the retention internal you have for the table? See: https://docs.delta.io/latest/delta-utility.html#remove-files-no-longer-referenced-by-a-delta-table
You can remove files no longer referenced by a Delta table and are older than the retention threshold by running the vacuum command on the table.
Upvotes: 1