title: How do I copy SQL Server 2012 database to localdb instance?
body: <p>I'm looking to copy a SQL Server 2012 Standard database to my localdb instance. I've tried the wizard which complains that localdb isn't a <em>SQL Server 2005 or later express instance</em>. I also did a backup/restore but upon the restore in my localdb I get the following error...</p>
  
  <p>Running this...</p>
  
  <pre><code>RESTORE DATABASE CSODev
  FROM DISK = 'C:\MyBckDir\CSODev.bak'
  WITH MOVE 'CSOdev_Data' TO 'C:\Users\cblair\CSOdev_Data.mdf',
  MOVE 'CSOdev_Log' TO 'C:\Users\cblair\CSOdev_Log.ldf',
  REPLACE
  </code></pre>
  
  <p>Error message I get...</p>
  
  <blockquote>
    <p>Processed 8752 pages for database 'CSODev', file 'CSOdev_Data' on file 1.<br>
    Processed 5 pages for database 'CSODev', file 'CSOdev_Log' on file 1.  </p>
    
    <p><em>Msg 1853, Level 16, State 1, Line 1</em><br>
    The logical database file 'CSOdev_Log' cannot be found. Specify the full path for the file.<br>
    <em>Msg 3167, Level 16, State 1, Line 1</em><br>
    RESTORE could not start database 'CSODev'.<br>
    <em>Msg 3013, Level 16, State 1, Line 1</em><br>
    RESTORE DATABASE is terminating abnormally.</p>
  </blockquote>
  
  <p>The database ends up in "Recovery Pending" mode.  It seems like it has issues with the log file.  I have tried 2 different backups in case one was just corrupted.</p>