summary refs log tree commit diff
path: root/synapse/storage/receipts.py
diff options
context:
space:
mode:
authorDavid Baker <dave@matrix.org>2016-08-18 17:53:44 +0100
committerDavid Baker <dave@matrix.org>2016-08-18 17:53:44 +0100
commit1e4217c90c730e8dc18e2f8ce11c15f498ad7909 (patch)
tree38414ef39db7b36e4917fcf0b82d36f7cfdd2fe3 /synapse/storage/receipts.py
parentUse tuple comparison (diff)
downloadsynapse-1e4217c90c730e8dc18e2f8ce11c15f498ad7909.tar.xz
Explicit join
Diffstat (limited to 'synapse/storage/receipts.py')
-rw-r--r--synapse/storage/receipts.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/receipts.py b/synapse/storage/receipts.py
index cb4e04a679..2c1df0e2b9 100644
--- a/synapse/storage/receipts.py
+++ b/synapse/storage/receipts.py
@@ -100,8 +100,8 @@ class ReceiptsStore(SQLBaseStore):
             sql = (
                 "SELECT rl.room_id, rl.event_id,"
                 " e.topological_ordering, e.stream_ordering"
-                " FROM receipts_linearized rl,"
-                " events e"
+                " FROM receipts_linearized AS rl"
+                " INNER JOIN events AS e USING (room_id, event_id)"
                 " WHERE rl.room_id = e.room_id"
                 " AND rl.event_id = e.event_id"
                 " AND user_id = ?"