[Q] Query two different tables

Discussion in 'MySQL' started by Eng_A_Moktar, Dec 2, 2009.

  1. #1
    I wanna Query two different tables ,
    I wanna query 5 column from table_1
    and query 3 column from table_2

    I tried Union All, but i get an error msg
    "The used SELECT statements have a different number of columns"

    any ideas ?
    Thanks
     
    Eng_A_Moktar, Dec 2, 2009 IP
  2. mastermunj

    mastermunj Well-Known Member

    Messages:
    687
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    110
    #2
    use JOIN.

    Have a look at this
     
    mastermunj, Dec 2, 2009 IP