Re: What's the fastest way to UPDATE?
Posted in 1994
} } Test 1: This is the Brute forse method like your option 5 and } was the fastest I could come up with. As others } suggested, you would want to turn logging off, and delete } the begin and commit work. } } ## Test 1 4GL Code } database zip } main } begin work } update zip set ( price ) = (price *1.1 ) where 1=1 } commit work } display "Update complete " } display "" } end main } } time: 1:25.12 The brute force method is going to be the best I would think since you need to update ALL rows. Since that is the case, shoot the 'where 1=1' - you don't need it. Also - if the updated field is an index you might try dropping it and hten recreating it. As always - check sqexplain.out - a SEQUENTIAL SCAN is what you really want. j. _____________________________________________________________________________ Jack Parker | Hewlett Packard, BSMC Boise, Idaho, USA| If you put all of the lawyers in jparker@hpbs3645.boi.hp.com | this country end to end, (208) 396-5388 (W) (208) 384-1623 (H) | it would be a good thing. _____________________________________________________________________________ Any opinions expressed herein are my own and not those of my employers. _____________________________________________________________________________