From f3d5f8a6f6bf686f6cbb08db32d1bf4f744f7267 Mon Sep 17 00:00:00 2001 From: Jens Schauder Date: Mon, 26 Oct 2020 15:04:03 +0100 Subject: [PATCH] DATAJPA-1622 - Polishing. Original pull request: #433. --- src/main/asciidoc/jpa.adoc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/asciidoc/jpa.adoc b/src/main/asciidoc/jpa.adoc index dec32b106..d43b46320 100644 --- a/src/main/asciidoc/jpa.adoc +++ b/src/main/asciidoc/jpa.adoc @@ -141,7 +141,7 @@ Spring Data JPA offers the following strategies to detect whether an entity is n 1. Version-Property and Id-Property inspection (*default*): By default Spring Data JPA inspects first if there is a Version-property of non-primitive type. - If there is, the entity is considered new if the value is `null`. + If there is, the entity is considered new if the value of that property is `null`. Without such a Version-property Spring Data JPA inspects the identifier property of the given entity. If the identifier property is `null`, then the entity is assumed to be new. Otherwise, it is assumed to be not new. @@ -302,7 +302,8 @@ public interface UserRepository extends JpaRepository { ---- ==== -Spring Data tries to resolve a call to these methods to a named query, starting with the simple name of the configured domain class, followed by the method name separated by a dot. So the preceding example would use the named queries defined earlier instead of trying to create a query from the method name. +Spring Data tries to resolve a call to these methods to a named query, starting with the simple name of the configured domain class, followed by the method name separated by a dot. +So the preceding example would use the named queries defined earlier instead of trying to create a query from the method name. [[jpa.query-methods.at-query]] === Using `@Query`