# 先将数据原来顺序进行排名,以及按照first_name升序进行排名得到 with t1 as ( select first_name, ROW_NUMBER() OVER() as t_rank1, ROW_NUMBER() OVER (ORDER BY first_name) as t_rank2 from employees ) # 想要排名为奇数 select first_name as first from t1 where MOD(t_rank2, 2) != 0 order by t_rank1;