Results 1 to 1 of 1
Thread: grouping mysql data by time
Feb 28, 2002, 08:11 #1
- Join Date
- Oct 2001
- 0 Post(s)
- 0 Thread(s)
grouping mysql data by time
I have a load of data in a table which has a date_time column (i.e. in format 2002-02-28 12:39:45) that specifies when the data was inserted.
I also have another column (named 'amount') in this table that contains integer values.
What I'd like to do is add the values (i.e. SUM(amount)) in the amount column based upon time.
For example, I want to add up all the amounts for each day of the month. I.e. there may be 100 rows for one day each containing a different amount.
I'd like the results to be returned as:
Does anyone know how to do this please?
Jasonhttp://www.DomainDip.com is a new, unique and fast domain name search tool! Find out where those free and available domain names are hiding right now, by performing a special domain name search.