Skip to content

Commit

Permalink
[FIX] fix count query
Browse files Browse the repository at this point in the history
  • Loading branch information
CokeLee777 committed Nov 28, 2023
1 parent f069eec commit 0d37a57
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public interface FollowJpaRepository extends JpaRepository<Follow, FollowId> {
"select f from Follow f "
+ "join fetch f.following following "
+ "where f.follower.id = :memberId",
countQuery = "select count(f) from Follow f")
countQuery = "select count(f) from Follow f where f.follower.id = :memberId")
Page<Follow> findFollowingsByMemberId(Long memberId, Pageable pageable);

@Query(
Expand All @@ -30,6 +30,6 @@ public interface FollowJpaRepository extends JpaRepository<Follow, FollowId> {
+ "from Follow f "
+ "inner join f.follower follower "
+ "where f.following.id = :memberId",
countQuery = "select count(f) from Follow f")
countQuery = "select count(f) from Follow f where f.following.id = :memberId")
Page<FollowerResponse> findFollowersByMemberId(Long memberId, Pageable pageable);
}

0 comments on commit 0d37a57

Please sign in to comment.