On Sat, 5 May 2007 21:03:27 -0400, jose isaias cabrera wrote: >Ok, I am going to push my luck. :-) Imagine the same data, what if I >wanted to get the sum of the other two columns also? I know how to do it >one at a time, so in this instance I would have to do 3 separate call using >sum or total, but is there a way that I could do it on the same call and get >the sum of columns c2 and c3, so that I would get something like this,
>a,11,19 >b,3,4 >c,6,9 >Yes, I know. I am pushing my luck. :-) create table t1 (c1,c2,c3); insert into t1 values ('a', 1, 2); insert into t1 values ('b', 3, 4); insert into t1 values ('c', 5, 6); insert into t1 values ('a', 9, 8); insert into t1 values ('a', 1, 9); insert into t1 values ('c', 1, 3); select c1, sum(c2), sum(c3) from t1 group by c1; ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------