Added suggestions for answers

This commit is contained in:
M66B
2023-04-06 09:46:51 +02:00
parent 06573cd57f
commit f5ebd8e052
3 changed files with 21 additions and 2 deletions

View File

@@ -74,6 +74,11 @@ public interface DaoAnswer {
" AND (:favorite OR NOT favorite)")
Integer getAnswerCount(boolean favorite);
@Query("SELECT DISTINCT `group` FROM answer" +
" WHERE NOT `group` IS NULL" +
" ORDER by `group` COLLATE NOCASE")
List<String> getGroups();
@Insert
long insertAnswer(EntityAnswer answer);