Backup All Users databases via Select and Cursor!
In this articlke we are going to focus on:
How to back up all user databases using one script?
One day at work I dealt with Sharepoint, I needed to install new updates. So, I needed to do backup of all Sharepoint databases, therefore I had to
come up with some script which would be able backup all databases.
We can use SELECT Statement for generating query, as you can see below:
Then copy the query and run backup!
Or, we can use my favorite CURSOR, the query is the following:
I hope that this short article helps you out!