Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello. I have data like that:
customer, date, amount1 1.11.2009 101 1.11.2009 101 3.11.2009 101 3.11.2009 202 3.11.2009 203 4.11.2009 40
I need make streight table and find sum of amount of last date for every customer.
customer, last date, amount
1 3.11.2009 30
2 3.11.2009 20
3 4.11.2009 40
Any idea?
LOAD customer as customer1, max(date) as date1
RESIDENT table1
GROUP BY customer;
LEFT JOIN
LOAD customer as customer1, date as date1, sum(amount) as amount1
GROUP BY customer, date;