Skip to content

Commit 735f321

Browse files
Update reference documentation.
Fix sorting query part that should be 'orderBy'. Original Pull Request: #2087
1 parent 2e33841 commit 735f321

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/main/asciidoc/reference/redis-repositories.adoc

+5-2
Original file line numberDiff line numberDiff line change
@@ -713,15 +713,18 @@ The following table provides an overview of the keywords supported for Redis and
713713
[[redis.repositories.queries.sort]]
714714
=== Sorting Query Method results
715715

716-
Redis repositories allow various approaches to define sorting order. Redis itself does not support in-flight sorting when retrieving hashes or sets. Therefore, Redis repository query methods construct a `Comparator` that is applied to the result before returning results as `List`. Let's take a look at the following example:
716+
Redis repositories allow various approaches to define sorting order.
717+
Redis itself does not support in-flight sorting when retrieving hashes or sets.
718+
Therefore, Redis repository query methods construct a `Comparator` that is applied to the result before returning results as `List`.
719+
Let's take a look at the following example:
717720

718721
.Sorting Query Results
719722
====
720723
[source,java]
721724
----
722725
interface PersonRepository extends RedisRepository<Person, String> {
723726
724-
List<Person> findByFirstnameSortByAgeDesc(String firstname); <1>
727+
List<Person> findByFirstnameOrderByAgeDesc(String firstname); <1>
725728
726729
List<Person> findByFirstname(String firstname, Sort sort); <2>
727730
}

0 commit comments

Comments
 (0)