The scenario required to hit this is definitely a bit weird, but I just happened to need weird. When a query joins on a windowed CTE, AND sorts by a coalesced left joined column, it produces
java.lang.IllegalArgumentException: Invalid or unknown parameter with name: ids_0_0
This stems from the fact that the ids_# parameters are never registered in the parameter manager, so when getObjectQueryById gets called it creates the query with only the param_# parameters registered. When PaginatedTypedQueryImpl iterates and calls setParameter the underlying AbstractCustomQuery doesn't have it in the parameter list, and throws the exception.
PR: #2011