i need to write a report function that picks values out of a mysql database, and then works out which it is.
it needs to be able to pickout the top 25 users, by the value of items they have bought, so if they have bought a sofa for £200 and another person has bought a sofa and three chairs for £500 then the second person will be above the first person. the problem is that they may have bought many itmes, which all have individual entries in a database. so i need to use sum() wich i can do, the problem is when i try and add validations so it only picks out the the value of the items they bought in 2002.
can anyone help??:rolleyes: