Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Lock one row of a table from all users

Re: Lock one row of a table from all users

From: Howard J. Rogers <hjr_at_dizwell.com>
Date: Sun, 16 May 2004 19:37:00 +1000
Message-ID: <40a7362e$0$1587$afc38c87@news.optusnet.com.au>


George Mansoor wrote:

> It's a security table in PeopleSoft. Trying to prevent security admins from
> changing the password for the application server account. Policy and other
> mechanisms haven't proven to be successful in getting folks to leave this
> account alone. If the account is changed, then the application servers can
> shutdown or not restart if booted.

Ah. This is a good example of where, if you explain the actual issue, you tend to get better advice than if you ask how to perform a specific action in the database.

In this case, why not write a before update trigger that says, in pseudo-code anyway,

if new.password <> old.password

        then raise error telling them to sod off; else

        allow the update to occur if it's sensible; end if;

If someone then tries to change the password, it errors out. If they are trying to change something else (which they are perhaps allowed to do) then it permits the change.

So no row locking needed, just code to prevent a column change.

Regards
HJR Received on Sun May 16 2004 - 04:37:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US