List:MySQL on Win32« Previous MessageNext Message »
From:ian_t_howarth Date:July 20 2004 1:24pm
Subject:Bad query structure...
View as plain text  
Hi,

I am trying to identify items with no records in a sub-set, such as a customer
with no purchases.  I have tried several different queries but none provide
the correct result set, eq:

SELECT Count(P.Ref)=0, C.Ref, C.Surname, C.Forename FROM Clients C JOIN
Purchases P ON C.Ref=P.Ref

Can anyone provide me with info as to the correct query structure?

 

TIA


__________________________________________________
Broadband from an unbeatable £15.99!

http://www.tiscali.co.uk/products/broadband/home.html?code=SM-NL-11AM



Thread
Bad query structure...ian_t_howarth20 Jul
  • Re: Bad query structure...SGreen20 Jul
  • Re: Bad query structure...Petr Vileta20 Jul
    • Re: Bad query structure...ian_t_howarth22 Jul
      • Re: Bad query structure...Petr Vileta22 Jul