Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

standby sql server 2005 significance and restore to active

Posted on 2008-10-16
5
Medium Priority
?
693 Views
Last Modified: 2010-04-21
In sql server 2005 what is the significance of the database in standby mode and how to make it active
0
Comment
Question by:Greens8301
  • 2
  • 2
5 Comments
 
LVL 6

Assisted Solution

by:bcsql
bcsql earned 400 total points
ID: 22732087
Standby mode when restoring a database lest you apply trans log backups to the databases and leaves the database in a read only mode. Useful in logshipping when you want to read the database you are logshipping to say for reporting. Use the with recovery option when restoring a database when all trans logs have been applied and you want the database out of readonly mode.

http://msdn.microsoft.com/en-us/library/ms188223(SQL.90).aspx
http://msdn.microsoft.com/en-us/library/ms177429(SQL.90).aspx

0
 
LVL 15

Expert Comment

by:jorge_toriz
ID: 22732094
The stand by mode put your database in a read-only mode, storing all the uncommited transactions in your stand by file... if you want to make it active, you can take your last log backup and restore it using WITH RECOVERY

This is commonly used in log shipping
0
 

Author Comment

by:Greens8301
ID: 22732245
Is there a T-SQL command to make it active WITH RECOVERY option

Thanks
0
 
LVL 15

Accepted Solution

by:
jorge_toriz earned 1600 total points
ID: 22732331
RESTORE LOG YourDBName
FROM DISK = 'C:\YourLast_LogBackup_File.trn'
WITH RECOVERY
0
 

Author Closing Comment

by:Greens8301
ID: 31506840
Thanks got the quick reponse
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will describe one method to parse a delimited string into a table of data.   Why would I do that you ask?  Let's say that you need to pass multiple parameters into a stored procedure to search for.  For our sake, we'll say that we wa…
There are some very powerful Dynamic Management Views (DMV's) introduced with SQL 2005. The two in particular that we are going to discuss are sys.dm_db_index_usage_stats and sys.dm_db_index_operational_stats.   Recently, I was involved in a di…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…

876 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question