Red Gate forums :: View topic - Correct Syntax for Restoring sQBHeaderOnly with Password
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Backup 7
SQL Backup 7 forum

Correct Syntax for Restoring sQBHeaderOnly with Password

Search in SQL Backup 7 forum
Post new topic   Reply to topic
Jump to:  
Author Message
pamozer



Joined: 20 Jan 2014
Posts: 13

PostPosted: Wed Mar 19, 2014 9:21 pm    Post subject: Correct Syntax for Restoring sQBHeaderOnly with Password Reply with quote

I am having issues with the syntax for sqbheaderonly in SQL SERVER Managment Studio
[code]
EXECUTE master..sqlbackup '-SQL "RESTORE SQBHEADERONLY FROM DISK = ''c:\backups\FULL_DB001_superbill_24305_prod_20140219_200928_encr.sqb''With Password='''teest'''"'
[/code]

Can someone please tell me what I am missing.

thanks
Back to top
View user's profile Send private message
pamozer



Joined: 20 Jan 2014
Posts: 13

PostPosted: Wed Mar 19, 2014 9:37 pm    Post subject: Here is the error I get Reply with quote

Syntax error: 'teest''' after 'c:\backups\FULL_DB001_superbill_24305_prod_20140219_200928_encr.sqb WITH PASSWORD ='
Back to top
View user's profile Send private message
petey



Joined: 24 Apr 2005
Posts: 2301

PostPosted: Thu Mar 20, 2014 10:37 am    Post subject: Reply with quote

Code:
EXECUTE master..sqlbackup '-SQL "RESTORE SQBHEADERONLY FROM DISK = ''c:\backups\FULL_DB001_superbill_24305_prod_20140219_200928_encr.sqb'' WITH PASSWORD = ''teest'' "'

or
Code:
EXECUTE master..sqlbackup '-SQL "RESTORE SQBHEADERONLY FROM DISK = [c:\backups\FULL_DB001_superbill_24305_prod_20140219_200928_encr.sqb] WITH PASSWORD = [teest] "'

_________________
Peter Yeoh
SQL Backup Consultant Developer
Associate, Yohz Software
Beyond compression - SQL Backup goodies under the hood, updated for version 7
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group