Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php on line 1077

Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php on line 1077

Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php on line 1079

Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php on line 1079

Deprecated: Using ${var} in strings is deprecated, use {$var} instead in /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php on line 1079

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home3/weo2000/public_html/offeman.com/wp-content/plugins/backup/com/core/functions.php:1077) in /home3/weo2000/public_html/offeman.com/wp-includes/rest-api/class-wp-rest-server.php on line 1831
{"id":55,"date":"2011-11-19T18:04:43","date_gmt":"2011-11-19T18:04:43","guid":{"rendered":"http:\/\/www.offeman.com\/2011\/11\/19\/MSSQLBackupAndRestoreCommandsUtilizingWithMove.aspx"},"modified":"2011-11-19T18:04:43","modified_gmt":"2011-11-19T18:04:43","slug":"ms-sql-backup-and-restore-commands-utilizing-with-move","status":"publish","type":"post","link":"https:\/\/offeman.com\/ms-sql-backup-and-restore-commands-utilizing-with-move\/","title":{"rendered":"MS SQL backup and restore commands (utilizing with move)"},"content":{"rendered":"

While I usually like to detach, copy\/rename, then reattach development databases, for online databases I often need to refer to these SQL commands:<\/p>\n

BACKUP DATABASE <\/span>MY_DATABASE <\/span>TO DISK<\/span>=<\/span>‘C:\\SQLBACKUPS\\MY_DATABASE_BACKUP20111117a.BACKUP’ <\/p>\n

<\/span>RESTORE FILELISTONLY FROM DISK<\/span>=<\/span>‘C:\\SQLBACKUPS\\MY_DATABASE_BACKUP20111117a.BACKUP’ <\/p>\n

<\/span>RESTORE DATABASE <\/span>MY_DATABASE_NEW <\/span>FROM DISK<\/span>=<\/span>‘C:\\SQLBACKUPS\\MY_DATABASE_BACKUP20111117a.BACKUP’
<\/span>WITH
  MOVE <\/span>‘MY_DATABASE_Data’ <\/span>TO <\/span>‘C:\\PRODUCTION_DATA\\MY_DATABASE.MDF’<\/span>,<\/strong>
  <\/span>MOVE <\/span>‘MY_DATABASE_Log’ <\/span>TO <\/span>‘C:\\PRODUCTION_DATA\\MY_DATABASE.LDF’ <\/p>\n

<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"

While I usually like to detach, copy\/rename, then reattach development databases, for online databases I often need to refer to these SQL commands: BACKUP DATABASE MY_DATABASE TO DISK=‘C:\\SQLBACKUPS\\MY_DATABASE_BACKUP20111117a.BACKUP’ RESTORE FILELISTONLY FROM DISK=‘C:\\SQLBACKUPS\\MY_DATABASE_BACKUP20111117a.BACKUP’ RESTORE DATABASE MY_DATABASE_NEW FROM DISK=‘C:\\SQLBACKUPS\\MY_DATABASE_BACKUP20111117a.BACKUP’ WITH   MOVE ‘MY_DATABASE_Data’ TO ‘C:\\PRODUCTION_DATA\\MY_DATABASE.MDF’,   MOVE ‘MY_DATABASE_Log’ TO ‘C:\\PRODUCTION_DATA\\MY_DATABASE.LDF’<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/posts\/55"}],"collection":[{"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/comments?post=55"}],"version-history":[{"count":0,"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/posts\/55\/revisions"}],"wp:attachment":[{"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/media?parent=55"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/categories?post=55"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/offeman.com\/wp-json\/wp\/v2\/tags?post=55"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}