From 2ba860f0452ce4147b845db75d79014d059c27ec Mon Sep 17 00:00:00 2001
From: Kapil Viren Ahuja <k.v.ahuja@gmail.com>
Date: Sat, 4 Mar 2017 11:42:14 +0530
Subject: Col case changes

---
 queries/roster.sql | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

(limited to 'queries/roster.sql')

diff --git a/queries/roster.sql b/queries/roster.sql
index 2344c7f..f6500fb 100644
--- a/queries/roster.sql
+++ b/queries/roster.sql
@@ -3,16 +3,16 @@ WITH rosters AS (SELECT
   JSONB_ARRAY_ELEMENTS(match.data->'relations') AS roster
 FROM match WHERE id=$1)
 SELECT
-roster->'data'->>'id' AS "apiId",
-matchid AS "match_apiId",
-(roster->'data'->'attributes'->'stats'->>'acesEarned')::int AS "acesEarned",
+roster->'data'->>'id' AS "api_id",
+matchid AS "match_api_id",
+(roster->'data'->'attributes'->'stats'->>'acesEarned')::int AS "aces_earned",
 (roster->'data'->'attributes'->'stats'->>'gold')::int AS "gold",
-(roster->'data'->'attributes'->'stats'->>'heroKills')::int AS "heroKills",
-(roster->'data'->'attributes'->'stats'->>'krakenCaptures')::int AS "krakenCaptures",
+(roster->'data'->'attributes'->'stats'->>'heroKills')::int AS "hero_kills",
+(roster->'data'->'attributes'->'stats'->>'krakenCaptures')::int AS "kraken_captures",
 roster->'data'->'attributes'->'stats'->>'side' AS "side",
-roster->'data'->'attributes'->'stats'->>'side' AS "teamColor",
-(roster->'data'->'attributes'->'stats'->>'turretKills')::int AS "turretKills",
-(roster->'data'->'attributes'->'stats'->>'turretsRemaining')::int AS "turretsRemaining",
+roster->'data'->'attributes'->'stats'->>'side' AS "team_color",
+(roster->'data'->'attributes'->'stats'->>'turretKills')::int AS "turret_kills",
+(roster->'data'->'attributes'->'stats'->>'turretsRemaining')::int AS "turrets_remaining",
 
 roster->'relations'->0->'data'->>'id' AS "participant_1",
 roster->'relations'->1->'data'->>'id' AS "participant_2",
-- 
cgit v1.3.1

