MySQL Lists are EOL. Please join:

List:General Discussion« Previous MessageNext Message »
From:Patrice Olivier-Wilson Date:April 29 2013 5:29pm
Subject:Rookie question
View as plain text  
Hi all:

I have a membership directory where folks can belong to more than one category. But all
folks do not qualify for a category. So I want to list folks who have qualified in a
category but not have them repeat. So if member 1 is in cat 3 and cat 5, I want their name
only to show up once. Here's what I have so far, but it shows a member listed more than

"SELECT * FROM directory WHERE duespaid = 'y' AND directory.category1 = 'y' OR
directory.category2 = 'y' OR directory.category3 = 'y' OR directory.category4 = 'y' OR
directory.category5 = 'y' OR directory.category6 = 'y' OR directory.category7 = 'y' OR
directory.category8 = 'y' ORDER BY member_ID ASC"

Any pointers, much appreciated.


Patrice Olivier-Wilson

"Everything will be alright in the end, so if it is not alright, it is not yet the end." -
Quote from movie: The Best Exotic Marigold Hotel

Rookie questionPatrice Olivier-Wilson29 Apr
  • Re: Rookie questionGary Smith29 Apr
    • RE: Rookie questionRick James30 Apr