Re: What's the fastest way to...
Posted in 1994
Jack Parker (jparker@hpbs3645.boi.hp.com) wrote: : > : > Re: : > >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. : > : > Earlier in the question, the asker stated he was using 4gl for the mass : > update. In 4gl if an update or delete is applied without a where clause, : > informix assumes it is a mistake and the program crashes. To do a mass : > update/delete in a 4gl program, a where clause that is always true (such as : > where 1=1) is needed. : > : > : Interesting. Our version of 4gl (4.10.UD2) just did an update against 241 : rows without a where clauseand without complaint. I also use a DELETE FROM : table without a where clause consistently without error. : C'mon back There may have been some other error on the same line that was corrected when the where 1 = 1 was added. 4gl _assumes_ 1 = 1 if no where clause is included. It's not a bad idea however, to include a "where 1 = 1" clause anyway. A good example of this is the construct statement: Build a construct, don't enter any values and then look at the "output: from the construct. Ta da 1=1. -- gburnore@netcom.com ------------------------------------------------------------------------------- How you look depends on where you go. -------------------------------------------------------------------------------