PDA

View Full Version : Help with mysql query on forumdisplay (left joins etc.)


mini2
08-12-2004, 09:01 AM
Gone

Dean C
08-12-2004, 09:06 AM
Where the query is run i.e. $DB_site->query replace that text with echo and see what it outputs. Post the result up here :)

Dean C
08-12-2004, 11:26 AM
On first glance I can see two things (possibly) wrong with the query. I don't believe you can LEFT JOIN to another table more than once. Secondly on the 'WHERE thead.threadid IN (' you have a big gap between the values halfway through. I don't know if mysql strips whitespace or not.

I don't know what to suggest as my MySQL knowledge is a little shaky. I think it may need a different kind of JOIN or possibly combining the two LEFT JOIN's into one using AND/OR when you JOIN the table ON.