我有这些表:
我正在尝试通过使用连接表来获取article_id, article_name, article_title, article_description
和article_date
获取。articles
username
users
user_articles
我试过这段代码:
SELECT E.article_id, E.article_title, E.article_description, E.article_date, u.username
FROM articles AS E, users as u
INNER JOIN user_articles as A ON A.article_id = E.article_id
INNER JOIN users as u2 ON u2.user_id = A.user_id
WHERE E.article_status = 1
我收到此错误消息:
Msg 4104, Level 16, State 1, Line 3
The multi-part identifier "E.article_id" could not be bound.
我正在使用 SQL Server 2012 Express。