SELECT 姓名,峰值,00 名次 FROM aa ORDER BY 姓名 ,峰值 DESC INTO CURSOR BB READWRITE UPDATE BB SET 名次=(SELECT COUNT(*)+1 FROM BB B WHERE BB.峰值<B.峰值 AND BB.姓名=B.姓名) FROM BB BROWSE FOR 名次<=2
坚守VFP最后的阵地
SELECT 姓名,峰值,00 名次 FROM aa ORDER BY 姓名 ,峰值 DESC INTO CURSOR BB READWRITE UPDATE BB SET 名次=(SELECT COUNT(*)+1 FROM BB B WHERE BB.峰值<B.峰值 AND BB.姓名=B.姓名) FROM BB BROWSE FOR 名次<=2