urgent please correct the sql

  • this sql giving sql syntex error ............

    Restore database Crew from disk = 'C:\SQL2005Backups\Crew\Full+1730.BAK'

    WITH move Crew to 'C:\SQL2005Backups\Crew.mdf',

    move Crew_log to 'C:\SQL2005Backups\Crew.ldf'

    Thanks

    Anoop

  • what is the error that you are getting?

  • here Crew is my database Error was

    Msg 102, Level 15, State 1, Line 2

    Incorrect syntax near Crew

  • anoop (12/4/2008)


    Restore database Crew from disk = 'C:\SQL2005Backups\Crew\Full+1730.BAK'

    WITH move Crew to 'C:\SQL2005Backups\Crew.mdf',

    move Crew_log to 'C:\SQL2005Backups\Crew.ldf'

    my changes are in red, put single quotes around the logical filenames like so

    Restore database Crew from disk = 'C:\SQL2005Backups\Crew\Full+1730.BAK'

    WITH move 'Crew' to 'C:\SQL2005Backups\Crew.mdf',

    move 'Crew_log' to 'C:\SQL2005Backups\Crew.ldf'

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Thanks for you quick response it is working 🙂

    Anoop

  • your welcome

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

Viewing 6 posts - 1 through 5 (of 5 total)

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