Don’t ever update your database without taking a backup first.
That shouldn’t need to be said, but it does.
I built a critical database system for a client, and it ran great for years.
Until Company B came along to install a new system. I’ll leave them unnamed, although do we really need to protect the guilty?
Anyway, they needed to install THEIR database.
Usually not a problem. You have SQL Server running, you add a database, you add another database, you even add a new instance if need be.
But what would possess you to delete the existing database, uninstall SQL Server, re-install it, set up your database, and then restore a 4-month old copy of MY database you found somewhere on the network?
It happened. All I could say was, “Wow…”.
Because of the particular nature of this client, the loss of a database like this could have crippled them for months, or even put them out of business completely.
Fortunately, I had them making regular backups, and after a massive panic on their part I was able to restore everything back to normal.
They lost a day’s worth of work before they noticed something was wrong, and another day waiting to have it fixed, but that was a minor inconvenience compared to what could have happened.
There are a lot of things I could have foreseen happening to the system that would require backups, but never once did it occur to me that another database “expert” would come in and flat out delete something that didn’t belong to them.
At the very least, they could have taken a backup first. Instead, they found an old copy and restored it, hoping nobody would notice.
If you are doing any kind of work on a database, no matter how minor, take a backup first. You never know what could go wrong…
I am a computer programmer specializing in building database software with ASP.NET MVC, C#, and SQL Server.