aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick/service
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/juick/service')
-rw-r--r--src/main/java/com/juick/service/MessagesServiceImpl.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/juick/service/MessagesServiceImpl.java b/src/main/java/com/juick/service/MessagesServiceImpl.java
index 3e09d204..2bae04e6 100644
--- a/src/main/java/com/juick/service/MessagesServiceImpl.java
+++ b/src/main/java/com/juick/service/MessagesServiceImpl.java
@@ -765,7 +765,7 @@ public class MessagesServiceImpl extends BaseJdbcService implements MessagesServ
return getNamedParameterJdbcTemplate().queryForList(
"SELECT messages.message_id FROM messages_tags INNER JOIN messages " +
- " USING (message_id) WHERE messages.user_id = :uid AND messages_tags.tag_id = :tid " +
+ " ON messages.message_id = messages_tags.message_id WHERE messages.user_id = :uid AND messages_tags.tag_id = :tid " +
(before > 0 ?
" AND messages.message_id < :before " : StringUtils.EMPTY) +
" AND messages.privacy >= :privacy ORDER BY messages.message_id DESC LIMIT 20",