diff --git a/source/src/main/java/one/nem/lacerta/source/database/dao/VcsRevDao.java b/source/src/main/java/one/nem/lacerta/source/database/dao/VcsRevDao.java index 3213ca28..2df991fe 100644 --- a/source/src/main/java/one/nem/lacerta/source/database/dao/VcsRevDao.java +++ b/source/src/main/java/one/nem/lacerta/source/database/dao/VcsRevDao.java @@ -21,7 +21,7 @@ public interface VcsRevDao { @Query("SELECT * FROM vcs_rev WHERE id IN (:ids)") List findByIds(List ids); - @Query("SELECT * FROM vcs_rev WHERE document_id = :documentId") + @Query("SELECT * FROM vcs_rev WHERE document_id = :documentId ORDER BY created_at ASC") List findByDocumentId(String documentId); @Query("SELECT * FROM vcs_rev WHERE document_id = :documentId ORDER BY created_at DESC LIMIT 1")