This error may occur when attempting to delete old queries that have been used in the filters of post parameters. This error will still show if the post parameter has been deleted while the filter was still set to selected and using the query.
We are currently evaluating this issue.
Steps to Duplicate
Go to Accounts Payable, Query.
Receive error: Query 'Query name' is used for filtering (Post Parameter ) and cannot be deleted.