我正在尝试获得数据库中电影的最低平均评分。
目前我有:
select movie.movietitle as "Lowest Average Rating"
from movie, rating
where movie.movieid = rating.movieid
group by movie.movietitle
having avg(rating.rating) = min(avg(rating.rating));
但我收到错误“组函数嵌套太深”。谁能为我提供正确的方法并解释为什么这不起作用?
谢谢