Question

I have powershell script which execute sql script on few database. I need write code, which roll back all databases to a previous state, if any error occurred. How to make this mechanism? Each call powerchell script create "bacpac" file. But If I understand correct, this backup can't be roll back to exist database.

Was it helpful?

Solution

Look up database transactions. They are an integral part of ACID database theory. There are lots of articles about transactions, the Technet page should be decent a starting point.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top