Re: [BUGS] problem with the sum function

2002-05-07 Thread Tom Lane
Marco Kienzle <[EMAIL PROTECTED]> writes: > herring=3D# select sum(agenum) from age where weightmeanage>0 and lengthcel= > l=3D160; > sum=20 > - > 77 > (1 row) > select INTO TABLE temp1 inst, year, month, lengthcell, sex, age, agenum, w= > eightmeanage from age where weightmeanage>0 and l

Re: [BUGS] problem with the sum function

2002-05-07 Thread Dmitry Tkach
'group by' must be your problem. If you remove that clause from your second query, you should then get the same result (77) sum'ing the temp table... I hope, it helps... Dima Marco Kienzle wrote: >The following problem occur using the sum() function (see the attached >file for all the details