-4

可能重复:
每个派生表都必须有自己的别名

SELECT * FROM (SELECT Customer , Count(Customer) AS Reservation FROM Reservation GROUP BY customer) WHERE Reservation>=8 ORDER BY 1;

并得到以下错误

#1248 - Every derived table must have its own alias.

同样适用于 MS Access。提前感谢您的帮助,谢谢!!!

4

2 回答 2

1

正是错误所说的,通过AS fooWHERE.

于 2012-05-12T04:50:21.527 回答
-1
SELECT 
    * 
FROM 
    (SELECT 
         Customer , 
         Count(Customer) AS Reservation 
     FROM 
         Reservation 
     GROUP BY 
         customer) AS SOMETABLEALIAS 
WHERE 
    Reservation>=8 
ORDER BY 1;
于 2012-05-12T04:50:28.330 回答