有人可以告诉我下面的代码有什么问题吗?
SELECT
u.regid AS `ID`,
SUBSTRING_INDEX(u.firstname,',','1') AS `First Name`,
SUBSTRING_INDEX(u.lastname,',','1') AS `Last Name`,
u.city1 AS City,
u.state1 AS State,
h.confirmation_number AS `Confirmation Number`,
u.hotel_rooming_list_id AS `Hotel Rooming List ID`,
u.regcode AS RegCode,
COUNT(*) AS `Total Over 18`,
u.regnum AS `Total People`
FROM
reg2018 AS u,
mealroom2018 AS i
INNER JOIN hotel_confirmation_number AS h ON h.regcode = u.regcode
WHERE u.cancel is NULL AND
u.mealroom = 'Y' AND
i.regcode = u.regcode AND
i.year < '2000'
GROUP BY u.regid
ORDER BY u.regid ASC
我得到的错误是#1054-'on子句'中的未知列'u.regcode'