Joining tables - restricting selected records

2005-06-28 Thread Russell Horn
This must have come up before, but I've not found it using a google search. I have two tables customer and purchases customer: customerID customerName purchases: purchaseID customerID purchaseDate purchaseValue Is it possible in MySQL to join the tables so I only get the value of

Re: Joining tables - restricting selected records

2005-06-28 Thread Mathias
Selon Russell Horn [EMAIL PROTECTED]: This must have come up before, but I've not found it using a google search. I have two tables customer and purchases customer: customerID customerName purchases: purchaseID customerID purchaseDate purchaseValue Is it possible in

Re: Joining tables - restricting selected records

2005-06-28 Thread Michael Stassen
Mathias wrote: Selon Russell Horn [EMAIL PROTECTED]: This must have come up before, but I've not found it using a google search. I have two tables customer and purchases customer: customerID customerName purchases: purchaseID customerID purchaseDate purchaseValue Is it possible in

Re: Joining tables - restricting selected records

2005-06-28 Thread Mathias
Selon Michael Stassen [EMAIL PROTECTED]: Mathias wrote: Selon Russell Horn [EMAIL PROTECTED]: This must have come up before, but I've not found it using a google search. I have two tables customer and purchases customer: customerID customerName purchases: purchaseID

Re: Joining tables - restricting selected records

2005-06-28 Thread Michael Stassen
Mathias wrote: sorry if i wasn't clear. i mean not select puchase_date, but max(purchase_date), i.e. use having clause. The join field is certainly customerId, or There is not sufficient info on tables. Hope that helps :o) Mathias How would you do that with HAVING? I believe the