Forum Discussion
Visual
Dec 08, 2025Copper Contributor
Truncate and load data
Hi Expert after truncate and load data ... how we can roll back to original data The enhancement for CBDW.DIM.ProcessDimDesk has been completed as per MKTTREX-4949 requirements. The stored proce...
BastiF
Dec 13, 2025MCT
Hi,
a TRUNCATE can only be rolled back if it was executed inside an explicit BEGIN TRANSACTION block.
If the TRUNCATE was executed normally (which is usually the case), it commits as a data definition operation immediately and cannot be undone. In that case, only a database backup or reload can restore the original data can help.
These are the ways SQL Server can roll back a TRUNCATE
- TRUNCATE direkt and stand alone can not be rolled back (exception BEGIN TRANSACTION)
- Only a database restore (full, differential, log) can recover the previous state
- Or reload the old data from an external source
Sorry for having no other feedback on this.
Best