Hello
We have an automated script that backups the production db and restores it in a staging db on the same server. We use the restore command with the "WITH MOVE" clause.
So far, so good. It would be nice if the logical filename could also be changed, otherwise the logical file name of the staging db would be the same as in the production db, which is a bit confusing.
I know that its possible to use the alter database command after the restore, using "MODIFY FILE" clause. Anyway, I'm looking for an option to have it done in 1 command...
Thx in advance.
Thomas
0
Answers
NAV/SQL Performance Optimization & Troubleshooting
STRYK System Improvement
The Blog - The Book - The Tool
Thanks a lot. And it's not possible to have it as option of the restore command, is it?
Regards
Thomas
As far as I know it's not possible. But why not just adding those few lines to your script?
NAV/SQL Performance Optimization & Troubleshooting
STRYK System Improvement
The Blog - The Book - The Tool