Skip to content

Commit

Permalink
Reflect IS NULL/IS NOT NULL usage for derived queries using `null…
Browse files Browse the repository at this point in the history
…` as argument.

Closes #3674
  • Loading branch information
mp911de committed Nov 14, 2024
1 parent 1db98f5 commit f3ac6ba
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/antora/modules/ROOT/pages/jpa/query-methods.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ The following table describes the keywords supported for JPA and what a method c
|`Distinct`|`findDistinctByLastnameAndFirstname`|`select distinct ... where x.lastname = ?1 and x.firstname = ?2`
|`And`|`findByLastnameAndFirstname`|`… where x.lastname = ?1 and x.firstname = ?2`
|`Or`|`findByLastnameOrFirstname`|`… where x.lastname = ?1 or x.firstname = ?2`
|`Is`, `Equals`|`findByFirstname`,`findByFirstnameIs`,`findByFirstnameEquals`|`… where x.firstname = ?1`
|`Is`, `Equals`|`findByFirstname`,`findByFirstnameIs`,`findByFirstnameEquals`|`… where x.firstname = ?1` (or `… where x.firstname IS NULL` if the argument is `null`)
|`Between`|`findByStartDateBetween`|`… where x.startDate between ?1 and ?2`
|`LessThan`|`findByAgeLessThan`|`… where x.age < ?1`
|`LessThanEqual`|`findByAgeLessThanEqual`|`… where x.age \<= ?1`
Expand All @@ -60,7 +60,7 @@ The following table describes the keywords supported for JPA and what a method c
|`EndingWith`|`findByFirstnameEndingWith`|`… where x.firstname like ?1` (parameter bound with prepended `%`)
|`Containing`|`findByFirstnameContaining`|`… where x.firstname like ?1` (parameter bound wrapped in `%`)
|`OrderBy`|`findByAgeOrderByLastnameDesc`|`… where x.age = ?1 order by x.lastname desc`
|`Not`|`findByLastnameNot`|`… where x.lastname <> ?1`
|`Not`|`findByLastnameNot`|`… where x.lastname <> ?1` (or `… where x.firstname IS NOT NULL` if the argument is `null`)
|`In`|`findByAgeIn(Collection<Age> ages)`|`… where x.age in ?1`
|`NotIn`|`findByAgeNotIn(Collection<Age> ages)`|`… where x.age not in ?1`
|`True`|`findByActiveTrue()`|`… where x.active = true`
Expand Down

0 comments on commit f3ac6ba

Please sign in to comment.