Oracle Error PLS-00631: PARTITION-BY and CLUSTER/ORDER-BY clauses must be used with the same function argument

Oracle Error Message

PLS-00631: PARTITION-BY and CLUSTER/ORDER-BY clauses must be used with the same function argument

Reason for the Error

PARTITION-BY and CLUSTER/ORDER-BY clauses are specified on different function arguments.

Solution

Use the same argument in both PARITITON-BY and CLUSTER/ORDER-BY clauses.