数据库有表persons:idintpointsintvoted_onintothercolumns我想知Prop有idx的行在第几行排名,具有相同点数的行具有相同的行排名。这个查询工作得很好而且很快:(但如果你知道更好的查询,请告诉我:)selectcount(*)frompersonspcrossjoin(selectpointsfrompersonspwherep.id=x)constwherep.points>const.points;但是现在我想升级查询,即voted_on较少但点数相同的人比voted_on多的人有更好的行排名。但是,具有相同点数和voted_on的人应该具