“When I tried to attach the sql server database file .mdf on client's machine.After attachment the database status is showing (Read-Only) (Eg.database name (Read-Only). It will allow to retrieve(select) the values from tables, etc. but won't allow to Insert, Update & Delete operations.
To make this read-only database to read-write, just execute the following query.
Make Database Read Only
USE [master]
GOALTER DATABASE [TESTDB] SET READ_ONLY WITH NO_WAIT
GO
Make Database Read/Write
USE [master]
GOALTER DATABASE [TESTDB] SET READ_WRITE WITH NO_WAIT
GO
I hope this post will help you.
Regards,
Gajanan
Comments
Post a Comment