#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Posts
    25
    Rep Power
    0
    Hi

    Iím trying to join two tables called Tutors and Course along the Course id column. Iím not sure how to do this and especially how to display such a join. Can you help?

    Thanks
    Lisa
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Posts
    81
    Rep Power
    15
    <BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">code:</font><HR><pre>
    SELECT *
    FROM tutors t, course c
    WHERE c.course_id = t.course_id
    [/code]
    should do the trick. If that behaviour isn't what you're looking for, check out the SELECT docs on the MySQL web page for info on left and outer joins.
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Posts
    25
    Rep Power
    0

    Thank you
    But I'm still struggling to display the results of the join in PHP. Any suggestions?

    Lisa


  6. #4
  7. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    NYC
    Posts
    1
    Rep Power
    0
    here's a good tutorial:
    http://hotwired.lycos.com/webmonkey/...tutorial4.html


    ------------------
  8. #5
  9. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Posts
    25
    Rep Power
    0
    Thanks!

Similar Threads

  1. inner join, conditional And sorting query
    By byte me in forum PHP Development
    Replies: 0
    Last Post: January 17th, 2004, 11:44 AM
  2. inner join, conditional And sorting query
    By byte me in forum MySQL Help
    Replies: 3
    Last Post: January 17th, 2004, 11:11 AM
  3. Help, please. Cant get the join to work
    By happybunny in forum MySQL Help
    Replies: 1
    Last Post: January 15th, 2004, 01:43 PM
  4. trouble with a join query
    By Chauzer in forum MySQL Help
    Replies: 5
    Last Post: January 9th, 2004, 05:34 PM

IMN logo majestic logo threadwatch logo seochat tools logo