BACKUP LOG question

  • How do I determine the device name in this script?

    BACKUP LOG MyDB TO <device_name>

    Thanks!

  • You do one of two things....

    1. you replace <device name> with the path you want to use:

    BACKUP LOG mydb TO 'C:\Backups\mydblog.bak'

    2. you create a 'dump device' and use that.

    Refer to the BOL for information on sp_addumpdevice. But basically it's:

    USE Master

    EXEC sp_addumpdevice 'disk', 'mydblog', 'c:\Backups\mydblog.bak'

    GO

    BACKUP LOG mydb TO mydblog

    -SQLBill

    BOL=Books OnLine=Microsoft SQL Server's HELP

    Installed as part of the Client Tools

    Found at Start>Programs>Microsoft SQL Server>Books OnLine

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply