BigTime Posted August 24, 2012 Share Posted August 24, 2012 Im getting the error: Unknown column 'data2.name' in 'field list' in this SELECT query and I'm at a loss.... The table exists the column exists, I can SQL query SELECT refreport.user, refreport.division, refreport.hometeam, refreport.awayteam, refreport.week, refreport.homeleague, refreport.homeconference, refreport.awayconference, data2.name, data2.email FROM refreport INNER JOIN data on data2.user=refreport.user WHERE gameid='$id'"; Thanks in advance! Link to comment https://forums.phpfreaks.com/topic/267531-inner-join-select-statement-problem/ Share on other sites More sharing options...
scootstah Posted August 24, 2012 Share Posted August 24, 2012 You're using "data2" but the table is "data", and you have set no aliases. Link to comment https://forums.phpfreaks.com/topic/267531-inner-join-select-statement-problem/#findComment-1372152 Share on other sites More sharing options...
BigTime Posted August 24, 2012 Author Share Posted August 24, 2012 see there? Thanks for your eyes, scootstah!! Link to comment https://forums.phpfreaks.com/topic/267531-inner-join-select-statement-problem/#findComment-1372172 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.