SQL> select * from t1;
ID AGE
---------- ----------
1 20
2 19
3 19
4 21
5 22
6 27
6 rows selected.
现在要求找出表中第三年轻的学生
方法1
第三年轻,也就意味着只有两个人比他小
SQL> select t11.*
2 from t1 t11
3 where 2=(select count(*) from t1 t22 where t11.age>t22.age);
ID AGE
---------- ----------
1 20