forked from MirrorHub/synapse
Fix on sqlite: use left rather than outer join
This commit is contained in:
parent
76d40f4904
commit
31aca5589c
1 changed files with 3 additions and 3 deletions
|
@ -65,11 +65,11 @@ class EndToEndKeyStore(SQLBaseStore):
|
||||||
"SELECT user_id, device_id, "
|
"SELECT user_id, device_id, "
|
||||||
" d.display_name AS device_display_name, "
|
" d.display_name AS device_display_name, "
|
||||||
" k.key_json"
|
" k.key_json"
|
||||||
" FROM e2e_device_keys_json k"
|
" FROM devices d"
|
||||||
" %s JOIN devices d USING (user_id, device_id)"
|
" %s JOIN e2e_device_keys_json k USING (user_id, device_id)"
|
||||||
" WHERE %s"
|
" WHERE %s"
|
||||||
) % (
|
) % (
|
||||||
"FULL OUTER" if include_all_devices else "LEFT",
|
"LEFT" if include_all_devices else "INNER",
|
||||||
" OR ".join("(" + q + ")" for q in query_clauses)
|
" OR ".join("(" + q + ")" for q in query_clauses)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue