justlukeyou Posted February 6, 2013 Share Posted February 6, 2013 Hi, The people on here were tremendously helpful in sorting out a join query which featured a query from the domain name. However I am now only trying to echo a list from the database but it also echos the same result multiple times. $query = mysql_query("SELECT eventname, firstname, eventdetails, eventlocation, eventcountry, eventid, eventstart, eventend, logo, company, id, supplierdetails1, eventid FROM users JOIN eventjobs ORDER BY eventid DESC LIMIT 8 "); I can get this to work (thanks to peoples help on here) but I cant get the above join to work which should be simpler! <?php $query = mysql_query("SELECT eventname, firstname, eventdetails, eventlocation, eventcountry, eventid, eventstart, eventend, logo, company, id FROM users JOIN eventjobs ON eventjobs.organiserid = users.id WHERE eventjobs.eventid = $eventid LIMIT 10 "); while($row = mysql_fetch_array($query)) { ?> Link to comment https://forums.phpfreaks.com/topic/274127-join-query-list-only/ Share on other sites More sharing options...
DavidAM Posted February 6, 2013 Share Posted February 6, 2013 FROM users JOIN eventjobs FROM users JOIN eventjobs ON eventjobs.organiserid = users.id See the difference? Link to comment https://forums.phpfreaks.com/topic/274127-join-query-list-only/#findComment-1410593 Share on other sites More sharing options...
justlukeyou Posted February 7, 2013 Author Share Posted February 7, 2013 Thanks mate. Link to comment https://forums.phpfreaks.com/topic/274127-join-query-list-only/#findComment-1410812 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.