So should I remove the ALTER DATABASE commands from the script? Remember, my problem to begin with was that I was getting an error message that said the database needed...
The code below is from a batch file I created to run the maintenance plan. The batch file gets executed by our Veritas backup software after the backup runs.