Jump to content

wspnut

New Members
  • Posts

    2
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

wspnut's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. OK, well, just an FYI. I got this working by doing the following code... but I assumed that the two would be equivalent. I would REALLY prefer a statement similar to the first post, so any ideas would be much appreciated: SELECT crn.id, person.fname FROM crn LEFT JOIN instructor_crn ON ( instructor_crn.cid = crn.id ) LEFT JOIN person ON ( person.id = instructor_crn.person ) WHERE crn.id = '6'
  2. Hey all. I'm running MySQL v4.1.20 at my company (yea, they're slow with upgrades) on PHP 4.4.7. We run a normalized table (with InnoDB) and I have to span a few bridges once in a while with JOIN and WHERE statements. The problem is, when I do the following JOIN statement, the system locks up and takes up 100% of the CPU: SELECT crn.id, person.fname FROM crn, instructor_crn LEFT JOIN person ON (instructor_crn.cid = crn.id AND person.id = instructor_crn.person) WHERE crn.id = '6' However, running this statement works perfectly: SELECT crn.id, instructor_crn.cid FROM crn LEFT JOIN instructor_crn ON (instructor_crn.cid = crn.id) WHERE crn.id = '6' Any help? Thanks --Andrew
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.