I was wondering if someone had an easy answer to this question:
Here is the table:
FIRSTNAME LASTNAME PLATE YEAR DATE MILEAGE
Bob Smith SF234 1997 5/13/01 3200
Bob Smith SF234 1997 8/12/01 9500
MARY JOHNSON BN987 1992 3/15/01 28000
MARY JOHNSON BN987 1992 5/12/01 33000
MARY JOHNSON BN987 1992 8/12/01 38000
PAT JACKSON PO234 1999 4/12/01 2100
PAT JACKSON PO234 1999 6/12/01 2700
PAT JACKSON PO234 1999 8/13/01 35000
The task is to:
1. Calculate the average number of days between transactions for all customers
2. Calculate the average mileage between transactions for all customers.
There are multiple transactions for every customer. There are about 25 000 customers and about 75 000 transactions.
I'm having a serious brain cramp this morning...
Does anyone know an easy way to solve this one....
Any help is much appreciated.
AVG ( DaysBetween ),
AVG ( MilesBetween)
Click Here to Expand Forum to Full Width