It looks like you want to use the PERCENTILE_DISC function if you want to get the actual value from the set, or PERCENTILE_CONT if you want to interpolate the value for a specific percentile, say 80%:
SELECT PERCENTILE_DISC(0.8) WITHIN GROUP(ORDER BY integer_col ASC) FROM some_table
EDIT
If you use PERCENTILE_DISC, it will return the actual value from the dataset, so if you need a larger value, you want to increase it by 1 (for an integer column).
source share