Index HQL/JPQL positional parameters in annotations

Proprietary

Replaces unindexed ? positional parameters with indexed ?1, ?2, etc. in an HQL/JPQL query string held in an annotation attribute matching the given pattern.

io.moderne.hibernate.update40.IndexHqlAnnotationPositionalParameters

Required

An annotation pattern whose HQL/JPQL query string attribute should be indexed. Use attributeName to specify which attribute holds the query if it is not value.

Optional

The annotation attribute that holds the HQL/JPQL query string. Defaults to value.

mod run . --recipe=io.moderne.hibernate.update40.IndexHqlAnnotationPositionalParameters \ -P annotationPattern=@jakarta.persistence.NamedQuery

Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.