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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Avoiding any locks in SQL Servers - read and understand....its magic.

Re: Avoiding any locks in SQL Servers - read and understand....its magic.

From: Galen Boyer <galenboyer_at_hotpop.com>
Date: 26 Jan 2004 14:16:09 -0600
Message-ID: <ur7xmii44.fsf@standardandpoors.com>


On 26 Jan 2004, boston103_at_hotmail.com wrote:

> The constraint is right there, in the statement itself:
>
> update t1 set amount=amount-80 where (select
> t1.amount+t2.amount from t1 join t2 on t1.id=t2.id) > 0;

How is the constraint in your statement? You have only restricted the selected rows. You have said nothing about what should be done with the rows on update.

What if I type:

  update employee set salary = salary*.1 +salary where salary < min_wage;

With your argument, the above should fail.

-- 
Galen Boyer
Received on Mon Jan 26 2004 - 14:16:09 CST

Original text of this message

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