stuck with simple query..... Plz have a look

From: Date: Wed, 07 Apr 2004 22:38:30 +0000
Subject: stuck with simple query..... Plz have a look
Groups: php.general 
Request: Send a blank email to php-general+get-182612@lists.php.net to get a copy of this message
We have two tables Table1: -------------------------
ID     |    Name
------------------------
1       |    name1
2       |    name2
3       |    name3
4       |    name4
Table2: ---------------------------------------------------------------------------------------------------
PL      |      PC       |    PA        |         Description
---------------------------------------------------------------------------------------------------
1        |      2           |      4        |         Some description for Project 1
2        |      3           |      1        |         Some description for Project 2
1        |      2           |      4        |         Some description for Project 3
4        |      1           |      3        |         Some description for Project 4
3        |      1           |      4        |         Some description for Project 5
2        |      3           |      1        |         Some description for Project 6
I need the output like.......... ---------------------------------------------------------------------------------
PL-Name        |          PC-Name        |         PA-Name        ---------------------------------------------------------------------------------
name1             |         name2               |        name4
name2             |         name3               |        name1
name1             |         name2               |        name4
name4             |         name1               |        name3
name3             |         name1               |        name4
name2             |         name3               |        name1
Please guide me how can i achieve this kind of result set. Regards, Tariq

« previous php.general (#182612) next »