Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2001
    Posts
    18

    Unanswered: Restore/Create new db using existing mdf and ldf

    Hi All,

    I'm sure there's a simple answer for this but I haven't found anything so far that gives me the info I'm needing, so if anyone could help, I'd be grateful!

    I've been given mdf and ldf files from an existing off-site database to be "restored" locally (sqlserver 7). Usually I restore from a backup file, so I haven't had any experience with this scenario.

    I've found info regarding sp_attach...if I create a new database locally and run sp_attach to point to the mdf and ldf files, will this work?

    Many thanks in advance for any suggestions!

    Cheers,
    Megan

  2. #2
    Join Date
    Oct 2001
    Posts
    18


    Have answered my own question and for anyone who might have the same issue, yes it can be done by sp_attach_db very easily.
    This will create a new database, and you just need to configure your users (sp_change_users_login), etc, again when it's attached.

    Easy as!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •