MySQL 报错

SELECT COUNT(1) FROM
(select tid from teacher where tname like '李%')

1248 - Every derived table must have its own alias, Time: 0.000000s

要给子查询的表 加一个伪名

SELECT COUNT(1) FROM
(select tid from teacher where tname like '李%') as fuck;

 

posted @ 2018-09-24 17:40  Niuli'blog  阅读(358)  评论(0编辑  收藏  举报