Fixed navigation count

This commit is contained in:
M66B 2019-06-25 10:01:39 +02:00
parent 78e48cd506
commit 1a5fa5e830
1 changed files with 1 additions and 1 deletions

View File

@ -44,7 +44,7 @@ public interface DaoAccount {
LiveData<List<EntityAccount>> liveSynchronizingAccounts();
@Query("SELECT account.*" +
", (SELECT COUNT(message.id)" +
", (SELECT COUNT(DISTINCT CASE WHEN message.msgid IS NULL THEN message.id ELSE message.msgid END)" +
" FROM message" +
" JOIN folder ON folder.id = message.folder" +
" WHERE message.account = account.id" +