Identify the target version or timestamp to restore to by querying the transaction log: SELECT version, timestamp, operation, operationParameters FROM (DESCRIBE HISTORY <table_name>) ORDER BY version DESC
Restore the table to a previous version: RESTORE TABLE <table_name> TO VERSION AS OF <version_number>; alternatively restore to a timestamp: RESTORE TABLE <table_name> TO TIMESTAMP AS OF '<timestamp>'
After the RESTORE completes, query the table to verify the data matches expectations for that historical version; check the operation summary in DESCRIBE HISTORY to confirm the RESTORE operation appears as the latest entry
If the table is referenced by downstream streaming jobs checkpointed against a Delta source, the RESTORE creates a new version; downstream streams reading from a checkpoint may need their startingVersion adjusted if they were already past the restored version
Communicate the rollback to dependent pipelines and consider placing a table comment or tag documenting the rollback reason and the version range that was reverted
Known gotchas
RESTORE requires that the data files for the target version still exist — they must not have been removed by VACUUM; if VACUUM was run with a retention period shorter than the age of the target version, the files are gone and RESTORE will fail
RESTORE on a table that has concurrent writers risks a race condition; coordinate with upstream pipelines to pause writes before restoring, then resume after validation
After RESTORE, the table's latest version increments beyond the restored version; Delta's transaction log is append-only so the RESTORE itself appears as a new commit — this means the erroneous versions are still visible in DESCRIBE HISTORY even though the data is rolled back
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp