Enum RankType
- All Implemented Interfaces:
Serializable,Comparable<RankType>
An enumeration of rank type, usable to show how exactly generate rank number.
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionis similar to the RANK by generating a unique rank number for each distinct row within the partition based on the order, starting at 1 for the first row in each partition, ranking the rows with equal values with the same rank number, except that it does not skip any rank, leaving no gaps between the ranks.Returns a unique rank number for each distinct row within the partition based on the order, starting at 1 for the first row in each partition, with the same rank for duplicate values and leaving gaps between the ranks; this gap appears in the sequence after the duplicate values.Returns a unique sequential number for each row within the partition based on the order, starting at 1 for the first row in each partition and without repeating or skipping numbers in the ranking result of each partition. -
Method Summary
-
Enum Constant Details
-
ROW_NUMBER
Returns a unique sequential number for each row within the partition based on the order, starting at 1 for the first row in each partition and without repeating or skipping numbers in the ranking result of each partition. If there are duplicate values within the row set, the ranking numbers will be assigned arbitrarily. -
RANK
Returns a unique rank number for each distinct row within the partition based on the order, starting at 1 for the first row in each partition, with the same rank for duplicate values and leaving gaps between the ranks; this gap appears in the sequence after the duplicate values. -
DENSE_RANK
is similar to the RANK by generating a unique rank number for each distinct row within the partition based on the order, starting at 1 for the first row in each partition, ranking the rows with equal values with the same rank number, except that it does not skip any rank, leaving no gaps between the ranks.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-