How do I set up a SQL Server connection to read only? I tried Googling and I found all the file mode = read only
, but it did not work (file mode keyword is not supported). The reference has been seen in the SQL CE specifications.
No luck with SQLite Read Only =
.
-Edit -
My connection string is below I have no clue to configure tables I do not know how to create user / permissions.
rdconn = new SqlConnection (@) (wrong) read-only = server =. \ SQLExpress; AttachDbFilename = test2.mdf; Database = dabo; Integrated Security = SSPI; User Instance = True; SELECT
Set to
Do you want?
Click on existing DB in SQL-Server Management Studio, after clicking on security-> users, find your user on it Right click -> Property-> Secureb. Just mark the selected icon, dismiss all others.
Manage permissions on here. Check
Permissions. P>
If you want DB to be read only for any user:
Optional database database name SET READ_ONLY
or more Read here for information
Comments
Post a Comment