diff --git a/source/src/main/java/one/nem/lacerta/source/database/dao/DocumentDao.java b/source/src/main/java/one/nem/lacerta/source/database/dao/DocumentDao.java index 01bcec67..b4d53202 100644 --- a/source/src/main/java/one/nem/lacerta/source/database/dao/DocumentDao.java +++ b/source/src/main/java/one/nem/lacerta/source/database/dao/DocumentDao.java @@ -28,9 +28,8 @@ public interface DocumentDao { @Query("SELECT * FROM Document WHERE id IN (:ids)") List findByIds(List ids); - @Query("SELECT * FROM Document WHERE public_path = :publicPath") - DocumentEntity findByPublicPath(String publicPath); - + @Query("SELECT * FROM Document WHERE public_path = :publicPath LIMIT :limit") + List findByPublicPathWithLimit(String publicPath, int limit); // Insert @Insert