Uploaded image for project: 'Spring Tool Suite'
  1. Spring Tool Suite
  2. STS-4313

Invalid derived query error shown on Spring Data repository methods annotated with @Procedure

    XMLWordPrintable

    Details

      Description

      If you add a method to a Spring Data repository which is annotated with @Procedure, and the method starts with a recognized prefix (find, get, count, ..) but it is not a fully correct query method name, the STS shows the error "Invalid derived query! No property ...!

      Example:

      PetRepository.java
      public interface PetRepository extends JpaRepository<Pet, Long> {
      	
      	@Procedure("PRC_PLUS1INOUT")
      	Integer getValuePlus1(@Param("arg") Integer arg);
      }
      

        Attachments

          Activity

            People

            Assignee:
            mlippert Martin Lippert
            Reporter:
            cordin Cèsar Ordiñana
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: