As a DBA, I have a collection of scripts that I use for anything from auto-fixing logins to seeing who has the DAC. Since I’ve been a DBA for a while (yeah, a while, we’ll go with that) I have quite the collection of scripts and I am constantly adding to it.
In the Prehistoric days of dinosaurs and floppy disks, I used to keep a backup copy of them on a 3 1/2" floppy. This was convenient and portable, so if I ever changed jobs, I could take my scripts with me.
Then we entered the Golden Age of writable CDs and I could burn them to a data CD. Still portable but a little more durable than a 3 1/2" floppy, I didn’t have to worry about keeping my CD away from magnets.
Carrying a CD around may have been more durable, but it certainly wasn’t more convenient. Enter the Renaissance Age of USB/Thumb drives. Holy Cow, I could copy all my scripts to a USB drive and fit it in my pocket, I could take it with me everywhere I went, now that’s convenient!
Enter the Industrial Age and we got smarter about how we did things. Hello Google Drive. No more having to carry around anything but lint in my pockets. As long as I had access to the internet, I had access to my scripts. Even if the internet were temporarily unavailable, I could still access the scripts on my local hard drive.
But then a funny thing happened, I modified one of my scripts to accommodate a specific version of SQL Server and accidentally overwrite the original file. We’ve all been there, that moment when you click the Save button instead of Save As. All the expletives rumbling around in your head because now you have to remember what it was before you overwrote it. Enter the Space Age, the days of redundancy checks and fail safes. We in the development community call it source control. When Microsoft announced it’s TFS Online offering three years ago, I couldn’t put my scripts in the the cloud fast enough. Of course the name has changed, but the idea remains the same, source control in the cloud. The great thing is that you can actually do it for free (for up to five people).
Will you learn from history and protect your scripts or are you doomed to repeat it?