what is shared lock in oracle ?? when it comes to play? why it is called read lock ? i go through a lots of docs but still i am not clear about this.

please guide me

it allows the associated resource to be shared, depending on the operations involved. Multiple users reading data can share the data, holding share locks to prevent concurrent access by a writer (who needs an exclusive lock). Several transactions can acquire share locks on the same resource.

An EXAMPLE := Shared lock simply means it is shared by all , isnt it ..So some people are accessing a table whose rows are not locked exclusively with DML's lets say and others are locking as well simultaneously to do some DML's but on some rows not all, So this means that oracle is allowing some to access some part, and some to lock some part with DML's to disallow drop and alter operations while it is happening. hope it helps

Or suppose a user selects a row or some rows using FOR UPDATE clause and in that case two locks will be placed isnt it, one will be exclusive lock on the row and the other would be a a ROW SHARE LOCK on the table itself. This will disallow other users putting an exclusive lock on the table, thus preventing them from altering the table structure.