summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--queries/player.sql3
1 files changed, 2 insertions, 1 deletions
diff --git a/queries/player.sql b/queries/player.sql
index 209aabb..d718391 100644
--- a/queries/player.sql
+++ b/queries/player.sql
@@ -9,6 +9,7 @@ participants AS (SELECT
JSONB_ARRAY_ELEMENTS(rosters.roster->'relations') AS participant
FROM rosters),
players AS (SELECT
+ participants.participant->'data'->'attributes'->'stats'->>'skillTier' AS skill_tier,
shardid,
matchdate,
JSONB_ARRAY_ELEMENTS(participants.participant->'relations') AS player
@@ -27,7 +28,7 @@ players.player->'data'->'attributes'->>'name' AS "name",
(players.player->'data'->'attributes'->'stats'->>'wins')::int AS "wins",
(players.player->'data'->'attributes'->'stats'->>'lifetimeGold')::float AS "lifetime_gold",
matchdate AS "last_match_created_date",
-
+skill_tier AS "skill_tier",
0 AS "streak"
FROM players