嗨,他的查询给了我以下错误:
“on 子句”中的未知列“m.home_team_id”
SELECT DISTINCT (
`m`.`match_id`), 
`m`.`competition_id`, 
`m`.`date`, 
`h`.`team_name` AS "homeTeam", `h`.`team_id` AS "homeTeamID", 
`a`.`team_name` AS "awayTeam", `a`.`team_id` AS "awayTeamID", 
`o`.`for`, `o`.`against` 
FROM `single` bs, `matches` m, `teams` t, `outcomes` o 
JOIN `teams` `h` ON `m`.`home_team_id`=`h`.`team_id` 
JOIN `teams` `a` ON `m`.`away_team_id`=`a`.`team_id` 
WHERE `bs`.`match_id`=`m`.`match_id` 
AND `m`.`score_id`=`o`.`outcome_id` 
AND `actual_return` IS NOT NULL`enter code here`
m是一个名为 match 的表的别名,它有列home_team_id,away_team_id所以我不知道为什么找不到该列?
艾伦。