This is interesting:
I did this for Feb in 2 different ways:
The first includes an order by, the second one is w/o the order by:

>sel CreditDate,sum(Creditamount)=s from Credits  where Creditdate between 
>2/1/2008 and 2/29/2008 group by CreditDate order by CreditDate
 CreditDate sum (Creditamou 
 ---------- --------------- 
 02/17/2008        5,217.95
 02/17/2008        5,217.95
 02/24/2008       10,939.29
 02/24/2008       10,939.29
 ---------- --------------- 
                  32,314.48

R>sel CreditDate,sum(Creditamount)=s from Credits  where Creditdate between 
2/1/2008 and 2/29/2008 group by CreditDate
 CreditDate sum (Creditamou 
 ---------- --------------- 
 02/17/2008        5,217.95
 02/24/2008       10,939.29
 02/17/2008        5,217.95
 02/24/2008       10,939.29
 ---------- --------------- 
                  32,314.48

And then without group by or order by:

sel sum(Creditamount) from Credits  where Creditdate between 2/1/2008 and 
2/29/2008
 sum (Creditamou 
 --------------- 
       16,157.24

Reply via email to