As far as I know joins can only provide you with a list consisting of
rows from a table, and what I need is to retrieve from multiple rows
and still be able to output multiple names and fetch them from the
same row.

Please show me the query for this if you know it.

Thanks in advance.

On Sep 17, 7:58 am, "vijay kashyap" <[EMAIL PROTECTED]> wrote:
> You can use joins to do this job, if you dont know how to use joins then
> please let me know ,so i can form the query for you
>
> On Mon, Sep 15, 2008 at 7:57 PM, major <[EMAIL PROTECTED]> wrote:
>
> > How is it possible to select multiple items from the same column.  For
> > example, I need to retrieve an employee name and a boss's name, based
> > on their id, from one name column.  Is it possible to get beyond
> > "SELECT name FROM name_list WHERE name_list.id=complay.employee_id"
> > and then "SELECT name FROM name_list WHERE
> > name_list.id=company.boss_id" ?
>
> > These are the tables:
> > name_list
> > id | name
> > company
> > employee_id | boss_id
>
> > Thanks in advance.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "PHP 
& MySQL" group.
To post to this group, send email to [EMAIL PROTECTED]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/phpmysql?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to