I agree with
I agree with Matthew Billingham, you cannot execute any sort/modify statement on an import parameter, so either define it as a changing parameter or copy its data to a local internal table that you will be allowed to sort/modify.
Regards,
Raymond