summaryrefslogtreecommitdiff
path: root/insert.sql
diff options
context:
space:
mode:
authorschneefux <schneefux+commit@schneefux.xyz>2017-02-26 13:30:41 +0100
committerschneefux <schneefux+commit@schneefux.xyz>2017-02-26 13:30:41 +0100
commit07dd572a1f61cb5feb3af84c20945a2b0d9b2f84 (patch)
treeb0c7ddf7f4c152982beecc678b29c91f41fef5fa /insert.sql
parent69cee93c3bfbf95e1dd5e20bc6aa64bd82f95634 (diff)
downloadapigrabber-07dd572a1f61cb5feb3af84c20945a2b0d9b2f84.tar.gz
apigrabber-07dd572a1f61cb5feb3af84c20945a2b0d9b2f84.zip
fix participants not being linked into roster
Diffstat (limited to 'insert.sql')
-rw-r--r--insert.sql2
1 files changed, 1 insertions, 1 deletions
diff --git a/insert.sql b/insert.sql
index be4dcae..a47906e 100644
--- a/insert.sql
+++ b/insert.sql
@@ -39,7 +39,7 @@
'data', rosters.data - 'relationships',
'relations', TO_JSONB(ARRAY(
SELECT * FROM linked_participants
- WHERE rosters.data->'relationships'->'participants'->'data' @> JSONB_BUILD_ARRAY(JSONB_BUILD_OBJECT('id', linked_participants.data->>'id', 'type', linked_participants.data->>'type'))
+ WHERE rosters.data->'relationships'->'participants'->'data' @> JSONB_BUILD_ARRAY(JSONB_BUILD_OBJECT('id', linked_participants.data->'data'->>'id', 'type', linked_participants.data->'data'->>'type'))
))
) AS data
FROM rosters