difference between standby and read-only

  • Can someone please tell me what is the difference between standby and read-only database

  • A standby database is part of a high-availability set where the database can be brought on-line (relatively) quickly for use.

    A read-only database is online, but you cannot perform any write operations on it.

    Wayne
    Microsoft Certified Master: SQL Server 2008
    Author - SQL Server T-SQL Recipes


    If you can't explain to another person how the code that you're copying from the internet works, then DON'T USE IT on a production system! After all, you will be the one supporting it!
    Links:
    For better assistance in answering your questions
    Performance Problems
    Common date/time routines
    Understanding and Using APPLY Part 1 & Part 2

  • To add to what Wayne said, a read_only database may or may not be a part of a high-availability set. You can change a database to read_only for archival purposes or the read_only database could be the secondary database in logshipping (where the database is also in standby mode).

    Jason...AKA CirqueDeSQLeil
    _______________________________________________
    I have given a name to my pain...MCM SQL Server, MVP
    SQL RNNR
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

  • Thanks Jason - I was thinking that, and forgot to put it in there.

    Wayne
    Microsoft Certified Master: SQL Server 2008
    Author - SQL Server T-SQL Recipes


    If you can't explain to another person how the code that you're copying from the internet works, then DON'T USE IT on a production system! After all, you will be the one supporting it!
    Links:
    For better assistance in answering your questions
    Performance Problems
    Common date/time routines
    Understanding and Using APPLY Part 1 & Part 2

  • NP Wayne

    Jason...AKA CirqueDeSQLeil
    _______________________________________________
    I have given a name to my pain...MCM SQL Server, MVP
    SQL RNNR
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

  • A database that is set as read_only is exactly that, can only be read no backups may be rstored. To write to the database you would need to perform

    ALTER DATABASE [MYDB] SET READ_WRITE

    A database that is in standby mode is READ ONLY and will allow further backup files to be restored providing users are not connected to the database. To recover the database you would perform

    ALTER DATABASE [MYDB] WITH RECOVERY

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • thanks everyone

Viewing 7 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply