Forum OpenACS Q&A: Re: How to batch update security_inherit_p efficiently?

Collapse
Posted by Don Baccus on
Get rid of the loop! Can you create a select statement that will find all the objects for you?

Something like

update foo
set bar = 0
where pkey in (select pkey
               from foo
               where ...)
should be much faster than doing 80,000 separate update statements.