List:General Discussion« Previous MessageNext Message »
From:Michael Satterwhite Date:July 10 2010 3:43am
Subject:Re: Query Help
View as plain text  
I believe you're describing a crosstab query. This should help you put it 
together:

http://rpbouman.blogspot.com/2005/10/creating-crosstabs-in-mysql.html

---Michael

On Friday, July 09, 2010 07:37:41 pm Phillip Baker wrote:
> Hello All,
> 
> 
> For the life of me I cannot remember how to make a query like this and what
> it is called.
> I know it is fairly basic though.
> 
> 
> Table 1
> Product_id Product_Name
> 
> Table 2
> Category_id, Category_name
> 
> Table 3
> Product_id, Category_id
> 
> Each product can have one or more categories.
> So I want a result that has
> 
> Product A one category other category
> Product B other category
> 
> Thanks in advance.
> 
> Blessed Be
> 
> Phillip
> 
> If you try to protect idiots from themselves, even if you succeed, you just
> wind up filling the world with idiots.
>    - - Doug Casey
Thread
Query HelpPhillip Baker10 Jul
  • Re: Query HelpMichael Satterwhite10 Jul
  • RE: Query HelpJay Blanchard12 Jul
    • Re: Query HelpPhillip Baker12 Jul