Protect/Lock Individual Rows

M

MDW

I'm on Access 97, and not even sure if this is possible.

I've got a table with >3000 rows in it. Of those rows,
there are about 20 that I don't want people to change. I
want to be able to read from them only.

Is it possible to indivually mark specific rows as read-
only? I'm sure there are methods involving seperating out
the rows in question and putting them in their own
table....but due to the architecture of my DB that would
not be possible.

There are other ways for me to fanagle this on my forms,
but I was hoping there is a lower-level solution.
 
T

Tim Ferguson

I've got a table with >3000 rows in it. Of those rows,
there are about 20 that I don't want people to change. I
want to be able to read from them only.

You can use Access security to shut the users out of the tables altogether,
and give them updateable queries that do not allow them to see the
forbidden rows.

HTH


Tim F
 
J

John Vinson

Is it possible to indivually mark specific rows as read-
only? I'm sure there are methods involving seperating out
the rows in question and putting them in their own
table....but due to the architecture of my DB that would
not be possible.

That's too bad... :-{(

What you could do is set database security to prohibit ANY access to
the table directly (except by yourself or other authorized
developers). Instead, create two Queries - one on the twenty
privileged rows, with read-only access; another with full rights on
the remaining rows. These will need to be displayed separately on
forms, as best as I can figure out - a UNION query would not be
updateable.

VBA code in the Form's BeforeUpdate event would be the other route.
But separate tables is certainly the simplest solution!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top