List:General Discussion« Previous MessageNext Message »
From:bharani kumar Date:May 30 2009 3:52am
Subject:Left join query
View as plain text  
Airport table

SlNo	Name	      Code	Auth	Location status
1	Chennai	       CHN	Yes	India         1
2.	Hydarabed	        HYD	Yes	India         0
3	walker	      WAK   Yes	uk            1


common table

SlNo	Name	              Code	      Type	     Location    status
1	Chennai	               CHN	      Airport	        India           1
2.	guest Road	       GR	      Seaport	India           1
3.	Hyderabad	               HYD	      Airport	        India           0
4.	John garden	       JG	      Seaport	India           0
5	walker	              WAK        airport            uk            1


Hi All

Can u please tell the query for the above table ,

Display the record which satisfy below condtions ,

1.Need to display airport name , Where airport status = 1 and common
table status = 1 and common table type = airport

Output somthing like below

AirportCode CommonCode AirportSlNo CommonSlNo  AirportName
CommonLocation Status Type

CHN                CHN                1                   1
      Chennai      india                  1        airport

WAK               WAK               3                    5
      walker         uk                   1        airport


Any idea ,,,,,,,,,




Thnaks




				


-- 
Regards
B.S.Bharanikumar
http://php-mysql-jquery.blogspot.com/
Thread
Left join querybharani kumar30 May
  • Re: Left join queryShiv31 May
    • RE: Left join queryGavin Towey2 Jun