• I have found that an automated means of restoring a database vs. using various forms of database replication such as log shipping or database mirroring really comes down to what the resultant database is going to be used for.

    For log shipping or database mirroring, I've deployed this type of solution for a High Availability solution. I've developed a similar script to copy & restore a production database to a test/UAT environment for just that. In my situation after the database has been restored there are some system related information that needs to be updated in order for the newly refreshed database can be utilized in the test/UAT platform.

    I like the Author's depth of his restore script and may find some use for it. None the less this type of processing will become handy sooner than later.

    Thanks for sharing.

    Kurt

    Kurt W. Zimmerman
    SR DBA
    Lefrak Organization
    New York, NY

    http://www.linkedin.com/in/kurtwzimmerman