I'm trying to get these three items out of my database however I don't think I'm using the correct JOIN
.
The 3 fields I need are:
fldDate
- Which is held inside oftblCompetition
fldCatName
- Which is held inside oftblCategory
fldName
- Which is held inside oftblImage
I have posted my Diagram of my tables with their field names to help explain:
My Query I have at present is:
$query ="SELECT `fldDate`, `fldCatName`, `fldName`
FROM `tblMembEntComp`
JOIN `tblImage` ON `tblMembEntComp`.`fldMemberID` = `tblMembEntComp`.`fldMemberID`
JOIN `tblCompetition` ON `tblMembEntComp`.`fldCompID`= `tblCompetition`.`fldCompID`
WHERE `fldMemberID` = 1;"
The error appearing is: Unknown column 'fldCatName' in 'field list'
, can someone explain where I'm going wrong.