Dallas Cowboys vs. Pittsburgh Steelers: Head-to-Head Reg Season and Playoffs Stats Comparison
--------------------------------------
header_comp
WITH
t1 AS (
SELECT team_id, SUM(win AND type="reg") as rsw, SUM(loss AND type="reg") as rsl, SUM(tie AND type="reg") as rst, SUM(win AND type="post") as pow, SUM(loss AND type="post") as pol
FROM sup_team_games
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND opp_team_id=?
),
t2 AS (
SELECT team_id, SUM(win AND type="reg") as rsw, SUM(loss AND type="reg") as rsl, SUM(tie AND type="reg") as rst, SUM(win AND type="post") as pow, SUM(loss AND type="post") as pol
FROM sup_team_games
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND opp_team_id=?
)
SELECT team_id, rs_wins, rs_losses, rs_ties, po_wins, po_losses, SUM(games) AS games, SUM(wins) AS wins, SUM(losses) AS losses, IF(SUM(wins)+SUM(losses), (SUM(wins)+IF(year_id > 1971,0.5*SUM(ties),0))/(SUM(wins)+SUM(losses)+IF(year_id > 1971,SUM(ties),0)), NULL) as win_loss_pct_csk, TRIM(LEADING '0' FROM ROUND(IF(SUM(wins)+SUM(losses), (SUM(wins)+IF(year_id > 1971,0.5*SUM(ties),0))/(SUM(wins)+SUM(losses)+IF(year_id > 1971,SUM(ties),0)), NULL),3)) AS win_loss_pct, SUM(points)/SUM(games) as team_ppg_csk, ROUND(SUM(points)/SUM(games),1) AS team_ppg, SUM(points_opp)/SUM(games) as team_oppg_csk, ROUND(SUM(points_opp)/SUM(games),1) AS team_oppg, SUM(is_playoff_team) AS is_playoff_team, SUM(is_conf_champion) AS is_conf_champion, SUM(is_champion) AS is_champion
FROM sup_team_seasons as ts
JOIN sup_phase_seasons USING (comp_id, phase_id, year_id)
JOIN sup_comp_seasons USING (comp_id, year_id)
LEFT JOIN (SELECT t1.team_id, t1.rsw as rs_wins, t1.rsl as rs_losses, t1.rst as rs_ties, t1.pow as po_wins, t1.pol as po_losses FROM t1
UNION SELECT t2.team_id, t2.rsw as rs_wins, t2.rsl as rs_losses, t2.rst as rs_ties, t2.pow as po_wins, t2.pol as po_losses
FROM t2) as xxx USING (team_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="reg"
GROUP BY team_id
ORDER BY team_id
SQL PARAMS -- $VAR1 = [
'dal',
'pit',
'pit',
'dal',
'pit',
'dal'
];
--------------------------------------
h2h_gamelogs
Page Setup Time: 0.00089 seconds
SELECT IF(away_team_id="dal","@","") as loc, IF(away_team_id="dal",away_score,home_score) as team1_score, IF(away_team_id="pit",away_score,home_score) as team2_score, game_id, date, game_id, sup_games.link as game_link, sup_venue_seasons.name as venue_name, city as venue_city, IF(overtimes, IF(overtimes>1, CONCAT(overtimes,"OT"), "OT"), "") as overtimes
FROM sup_games
JOIN (SELECT game_id, year_id, comp_id, phase_id, team_id as away_team_id, opp_team_id, opp_comp_id, opp_phase_id, team_game_num_season, home_away_neutral FROM sup_team_games) as tg USING (game_id, away_team_id)
JOIN sup_phase_seasons USING (comp_id, phase_id, year_id)
LEFT JOIN sup_venues USING (venue_id)
LEFT JOIN sup_venue_seasons USING (venue_id, year_id)
WHERE ((away_team_id=? AND home_team_id=?) OR (away_team_id=? AND home_team_id=?))
AND home_score IS NOT NULL
AND type="reg"
ORDER BY date DESC LIMIT 0, 20
SQL PARAMS -- $VAR1 = [
'dal',
'pit',
'pit',
'dal'
];
Query Time: 0.04 seconds
SELECT IF(away_team_id="dal","@","") as loc, IF(away_team_id="dal",away_score,home_score) as team1_score, IF(away_team_id="pit",away_score,home_score) as team2_score, game_id, date, game_id, sup_games.link as game_link, sup_venue_seasons.name as venue_name, city as venue_city, IF(overtimes, IF(overtimes>1, CONCAT(overtimes,"OT"), "OT"), "") as overtimes
FROM sup_games
JOIN (SELECT game_id, year_id, comp_id, phase_id, team_id as away_team_id, opp_team_id, opp_comp_id, opp_phase_id, team_game_num_season, home_away_neutral FROM sup_team_games) as tg USING (game_id, away_team_id)
JOIN sup_phase_seasons USING (comp_id, phase_id, year_id)
LEFT JOIN sup_venues USING (venue_id)
LEFT JOIN sup_venue_seasons USING (venue_id, year_id)
WHERE ((away_team_id=? AND home_team_id=?) OR (away_team_id=? AND home_team_id=?))
AND home_score IS NOT NULL
AND type="post"
ORDER BY date DESC LIMIT 0, 20
SQL PARAMS -- $VAR1 = [
'dal',
'pit',
'pit',
'dal'
];
Query Time: 0.05 seconds
Table Build Time: 0.04 seconds
Table Build Time: 0.03 seconds
--------------------------------------
h2h_records
Page Setup Time: 0.00066 seconds
WITH
tr1 AS (
SELECT year_id, comp_id, COUNT(*) AS games, SUM(win=1) AS wins, SUM(loss=1) AS losses, SUM(points) AS points
FROM sup_team_games
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND opp_team_id=?
AND type="reg"
GROUP BY year_id
),
tr2 AS (
SELECT year_id, comp_id, COUNT(*) AS games, SUM(win=1) AS wins, SUM(loss=1) AS losses, SUM(points) AS points
FROM sup_team_games
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND opp_team_id=?
AND type="reg"
GROUP BY year_id
)
SELECT year_id as year_id_csk, year_id as year_id, tr1.comp_id, tr1.games AS tr1_games, tr2.games AS tr2_games, tr1.wins AS tr1_wins, tr2.wins AS tr2_wins, tr1.losses AS tr1_losses, tr2.losses AS tr2_losses, tr1.points AS tr1_points, tr2.points AS tr2_points
FROM tr1
JOIN tr2 USING (year_id)
WHERE 1
GROUP BY year_id
ORDER BY year_id
SQL PARAMS -- $VAR1 = [
'dal',
'pit',
'pit',
'dal'
];
Query Time: 0.03 seconds
WITH
tr1 AS (
SELECT year_id, comp_id, COUNT(*) AS games, SUM(win=1) AS wins, SUM(loss=1) AS losses, SUM(points) AS points
FROM sup_team_games
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND opp_team_id=?
AND type="post"
GROUP BY year_id
),
tr2 AS (
SELECT year_id, comp_id, COUNT(*) AS games, SUM(win=1) AS wins, SUM(loss=1) AS losses, SUM(points) AS points
FROM sup_team_games
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND opp_team_id=?
AND type="post"
GROUP BY year_id
)
SELECT year_id as year_id_csk, year_id as year_id, tr1.comp_id, tr1.games AS tr1_games, tr2.games AS tr2_games, tr1.wins AS tr1_wins, tr2.wins AS tr2_wins, tr1.losses AS tr1_losses, tr2.losses AS tr2_losses, tr1.points AS tr1_points, tr2.points AS tr2_points
FROM tr1
JOIN tr2 USING (year_id)
WHERE 1
GROUP BY year_id
ORDER BY year_id
SQL PARAMS -- $VAR1 = [
'dal',
'pit',
'pit',
'dal'
];
Query Time: 0.03 seconds
Table Build Time: 0.05 seconds
Table Build Time: 0.04 seconds
--------------------------------------
h2h_pass
Page Setup Time: 0.00274 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_cmp) AS pass_cmp, SUM(pass_att) AS pass_att, (SUM(pass_att)-SUM(pass_cmp)) AS pass_inc, IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL) as pass_cmp_pct_csk, ROUND(100 * (IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL)),1) AS pass_cmp_pct, SUM(pass_yds) AS pass_yds, SUM(pass_td) AS pass_td, SUM(pass_int) AS pass_int, SUM(int_ret_td) AS int_ret_td, IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL) as pass_td_pct_csk, ROUND(100 * (IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL)),1) AS pass_td_pct, IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL) as pass_int_pct_csk, ROUND(100 * (IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL)),1) AS pass_int_pct, SUM(pass_sacked) AS pass_sacked, SUM(pass_sacked_yds) AS pass_sacked_yds, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL) as pass_sacked_pct_csk, ROUND(100 * (IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL)),2) AS pass_sacked_pct, IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL) as pass_yds_per_att_csk, ROUND(IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL),1) AS pass_yds_per_att, IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL) as pass_adj_yds_per_att_csk, ROUND(IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL),2) AS pass_adj_yds_per_att, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL) as pass_adj_net_yds_per_att_csk, ROUND(IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL),2) AS pass_adj_net_yds_per_att, IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL) as pass_yds_per_cmp_csk, ROUND(IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL),1) AS pass_yds_per_cmp
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.03 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_cmp) AS pass_cmp, SUM(pass_att) AS pass_att, (SUM(pass_att)-SUM(pass_cmp)) AS pass_inc, IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL) as pass_cmp_pct_csk, ROUND(100 * (IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL)),1) AS pass_cmp_pct, SUM(pass_yds) AS pass_yds, SUM(pass_td) AS pass_td, SUM(pass_int) AS pass_int, SUM(int_ret_td) AS int_ret_td, IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL) as pass_td_pct_csk, ROUND(100 * (IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL)),1) AS pass_td_pct, IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL) as pass_int_pct_csk, ROUND(100 * (IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL)),1) AS pass_int_pct, SUM(pass_sacked) AS pass_sacked, SUM(pass_sacked_yds) AS pass_sacked_yds, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL) as pass_sacked_pct_csk, ROUND(100 * (IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL)),2) AS pass_sacked_pct, IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL) as pass_yds_per_att_csk, ROUND(IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL),1) AS pass_yds_per_att, IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL) as pass_adj_yds_per_att_csk, ROUND(IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL),2) AS pass_adj_yds_per_att, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL) as pass_adj_net_yds_per_att_csk, ROUND(IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL),2) AS pass_adj_net_yds_per_att, IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL) as pass_yds_per_cmp_csk, ROUND(IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL),1) AS pass_yds_per_cmp
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.04 seconds
Table Build Time: 0.07 seconds
Table Build Time: 0.04 seconds
--------------------------------------
h2h_rec
Page Setup Time: 0.00096 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(rush_att) AS rush_att, SUM(rush_yds) AS rush_yds, IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL) as rush_yds_per_att_csk, ROUND(IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL),1) AS rush_yds_per_att, SUM(rush_td) AS rush_td
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.03 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(rush_att) AS rush_att, SUM(rush_yds) AS rush_yds, IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL) as rush_yds_per_att_csk, ROUND(IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL),1) AS rush_yds_per_att, SUM(rush_td) AS rush_td
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.03 seconds
Table Build Time: 0.05 seconds
Table Build Time: 0.04 seconds
--------------------------------------
h2h_kick
Page Setup Time: 0.00144 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(xpm) AS xpm, SUM(xpa) AS xpa, IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL) as xp_pct_csk, ROUND(100 * (IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL)),1) AS xp_pct, SUM(fgm) AS fgm, SUM(fga) AS fga, IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL) as fg_pct_csk, ROUND(100 * (IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL)),1) AS fg_pct, SUM(two_pt_md) AS two_pt_md, SUM(punt) AS punt, SUM(punt_yds) AS punt_yds, IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL) as punt_yds_per_punt_csk, ROUND(IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL),1) AS punt_yds_per_punt, SUM(punt_blocked) AS punt_blocked
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.02 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(xpm) AS xpm, SUM(xpa) AS xpa, IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL) as xp_pct_csk, ROUND(100 * (IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL)),1) AS xp_pct, SUM(fgm) AS fgm, SUM(fga) AS fga, IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL) as fg_pct_csk, ROUND(100 * (IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL)),1) AS fg_pct, SUM(two_pt_md) AS two_pt_md, SUM(punt) AS punt, SUM(punt_yds) AS punt_yds, IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL) as punt_yds_per_punt_csk, ROUND(IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL),1) AS punt_yds_per_punt, SUM(punt_blocked) AS punt_blocked
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.03 seconds
Table Build Time: 0.09 seconds
Table Build Time: 0.05 seconds
--------------------------------------
h2h_return
Page Setup Time: 0.00113 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(kick_ret) AS kick_ret, SUM(kick_ret_yds) AS kick_ret_yds, IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL) as kick_ret_yds_per_ret_csk, ROUND(IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL),1) AS kick_ret_yds_per_ret, SUM(kick_ret_td) AS kick_ret_td, SUM(punt_ret) AS punt_ret, SUM(punt_ret_yds) AS punt_ret_yds, IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL) as punt_ret_yds_per_ret_csk, ROUND(IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL),1) AS punt_ret_yds_per_ret, SUM(punt_ret_td) AS punt_ret_td
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.02 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(kick_ret) AS kick_ret, SUM(kick_ret_yds) AS kick_ret_yds, IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL) as kick_ret_yds_per_ret_csk, ROUND(IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL),1) AS kick_ret_yds_per_ret, SUM(kick_ret_td) AS kick_ret_td, SUM(punt_ret) AS punt_ret, SUM(punt_ret_yds) AS punt_ret_yds, IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL) as punt_ret_yds_per_ret_csk, ROUND(IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL),1) AS punt_ret_yds_per_ret, SUM(punt_ret_td) AS punt_ret_td
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.03 seconds
Table Build Time: 0.04 seconds
Table Build Time: 0.05 seconds
--------------------------------------
h2h_defense
Page Setup Time: 0.00437 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="reg"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_sacked_opp) AS pass_sacked_opp, SUM(tackles_loss) AS tackles_loss, SUM(qb_knockdown) AS qb_knockdown, SUM(pressures) AS pressures, SUM(def_int) AS def_int, SUM(def_int_td) AS def_int_td, SUM(fumbles) AS fumbles, SUM(fumbles_rec) AS fumbles_rec, SUM(fumbles_rec_yds) AS fumbles_rec_yds, SUM(fumbles_rec_td) AS fumbles_rec_td, SUM(fumbles_forced) AS fumbles_forced
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.02 seconds
WITH
t1gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
),
t2gms AS (
SELECT game_id
FROM sup_team_games
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE (team_id=?)
AND type="post"
)
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_sacked_opp) AS pass_sacked_opp, SUM(tackles_loss) AS tackles_loss, SUM(qb_knockdown) AS qb_knockdown, SUM(pressures) AS pressures, SUM(def_int) AS def_int, SUM(def_int_td) AS def_int_td, SUM(fumbles) AS fumbles, SUM(fumbles_rec) AS fumbles_rec, SUM(fumbles_rec_yds) AS fumbles_rec_yds, SUM(fumbles_rec_td) AS fumbles_rec_td, SUM(fumbles_forced) AS fumbles_forced
FROM sup_team_games as st
JOIN sup_games USING (game_id)
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
JOIN t1gms USING (game_id)
JOIN t2gms USING (game_id)
WHERE home_score IS NOT NULL
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'dal',
'pit'
];
Query Time: 0.03 seconds
Table Build Time: 0.09 seconds
Table Build Time: 0.04 seconds
--------------------------------------
sum_pass
Page Setup Time: 0.00301 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_cmp IS NULL) as pass_cmp_incomplete, SUM(pass_cmp) AS pass_cmp, SUM(pass_att IS NULL) as pass_att_incomplete, SUM(pass_att) AS pass_att, SUM(pass_cmp IS NULL)+SUM(pass_att IS NULL) as pass_inc_incomplete, (SUM(pass_att)-SUM(pass_cmp)) AS pass_inc, IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL) as pass_cmp_pct_csk, SUM(pass_att IS NULL)+SUM(pass_cmp IS NULL) as pass_cmp_pct_incomplete, ROUND(100 * (IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL)),1) AS pass_cmp_pct, SUM(pass_yds IS NULL) as pass_yds_incomplete, SUM(pass_yds) AS pass_yds, SUM(pass_td IS NULL) as pass_td_incomplete, SUM(pass_td) AS pass_td, SUM(pass_int IS NULL) as pass_int_incomplete, SUM(pass_int) AS pass_int, IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL) as pass_td_pct_csk, SUM(pass_td IS NULL)+SUM(pass_att IS NULL) as pass_td_pct_incomplete, ROUND(100 * (IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL)),1) AS pass_td_pct, IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL) as pass_int_pct_csk, SUM(pass_att IS NULL)+SUM(pass_int IS NULL) as pass_int_pct_incomplete, ROUND(100 * (IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL)),1) AS pass_int_pct, IF(SUM(pass_att),
ROUND(100 *
(1.0 / 6.0) *
(LEAST(GREATEST(((SUM(pass_cmp) / SUM(pass_att)) - 0.3) / 0.2, 0), 2.375)
+ LEAST(GREATEST(((SUM(pass_yds) / SUM(pass_att)) - 3.0) / 4.0, 0.0), 2.375)
+ LEAST(GREATEST( (SUM(pass_td) / SUM(pass_att)) / 0.05, 0.0), 2.375)
+ LEAST(GREATEST((0.095 - (SUM(pass_int) / SUM(pass_att))) / 0.04, 0.0), 2.375)
),
1), NULL
)
as pass_rating_csk, SUM(pass_yds IS NULL)+SUM(pass_att IS NULL)+SUM(pass_td IS NULL)+SUM(pass_cmp IS NULL)+SUM(pass_int IS NULL) as pass_rating_incomplete, ROUND(IF(SUM(pass_att),
ROUND(100 *
(1.0 / 6.0) *
(LEAST(GREATEST(((SUM(pass_cmp) / SUM(pass_att)) - 0.3) / 0.2, 0), 2.375)
+ LEAST(GREATEST(((SUM(pass_yds) / SUM(pass_att)) - 3.0) / 4.0, 0.0), 2.375)
+ LEAST(GREATEST( (SUM(pass_td) / SUM(pass_att)) / 0.05, 0.0), 2.375)
+ LEAST(GREATEST((0.095 - (SUM(pass_int) / SUM(pass_att))) / 0.04, 0.0), 2.375)
),
1), NULL
),
1) AS pass_rating, SUM(pass_sacked IS NULL) as pass_sacked_incomplete, SUM(pass_sacked) AS pass_sacked, SUM(pass_sacked_yds IS NULL) as pass_sacked_yds_incomplete, SUM(pass_sacked_yds) AS pass_sacked_yds, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL) as pass_sacked_pct_csk, SUM(pass_att IS NULL)+SUM(pass_sacked IS NULL) as pass_sacked_pct_incomplete, ROUND(100 * (IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL)),2) AS pass_sacked_pct, IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL) as pass_yds_per_att_csk, SUM(pass_att IS NULL)+SUM(pass_yds IS NULL) as pass_yds_per_att_incomplete, ROUND(IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL),1) AS pass_yds_per_att, IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL) as pass_adj_yds_per_att_csk, SUM(pass_int IS NULL)+SUM(pass_td IS NULL)+SUM(pass_att IS NULL)+SUM(pass_yds IS NULL) as pass_adj_yds_per_att_incomplete, ROUND(IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL),2) AS pass_adj_yds_per_att, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL) as pass_adj_net_yds_per_att_csk, SUM(pass_td IS NULL)+SUM(pass_sacked_yds IS NULL)+SUM(pass_att IS NULL)+SUM(pass_yds IS NULL)+SUM(pass_int IS NULL)+SUM(pass_sacked IS NULL) as pass_adj_net_yds_per_att_incomplete, ROUND(IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL),2) AS pass_adj_net_yds_per_att, IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL) as pass_yds_per_cmp_csk, SUM(pass_yds IS NULL)+SUM(pass_cmp IS NULL) as pass_yds_per_cmp_incomplete, ROUND(IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL),1) AS pass_yds_per_cmp
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="reg"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_cmp IS NULL) as pass_cmp_incomplete, SUM(pass_cmp) AS pass_cmp, SUM(pass_att IS NULL) as pass_att_incomplete, SUM(pass_att) AS pass_att, SUM(pass_cmp IS NULL)+SUM(pass_att IS NULL) as pass_inc_incomplete, (SUM(pass_att)-SUM(pass_cmp)) AS pass_inc, IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL) as pass_cmp_pct_csk, SUM(pass_att IS NULL)+SUM(pass_cmp IS NULL) as pass_cmp_pct_incomplete, ROUND(100 * (IF(SUM(pass_att), SUM(pass_cmp)/SUM(pass_att), NULL)),1) AS pass_cmp_pct, SUM(pass_yds IS NULL) as pass_yds_incomplete, SUM(pass_yds) AS pass_yds, SUM(pass_td IS NULL) as pass_td_incomplete, SUM(pass_td) AS pass_td, SUM(pass_int IS NULL) as pass_int_incomplete, SUM(pass_int) AS pass_int, IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL) as pass_td_pct_csk, SUM(pass_td IS NULL)+SUM(pass_att IS NULL) as pass_td_pct_incomplete, ROUND(100 * (IF(SUM(pass_att), SUM(pass_td)/SUM(pass_att), NULL)),1) AS pass_td_pct, IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL) as pass_int_pct_csk, SUM(pass_att IS NULL)+SUM(pass_int IS NULL) as pass_int_pct_incomplete, ROUND(100 * (IF(SUM(pass_att), SUM(pass_int)/SUM(pass_att), NULL)),1) AS pass_int_pct, IF(SUM(pass_att),
ROUND(100 *
(1.0 / 6.0) *
(LEAST(GREATEST(((SUM(pass_cmp) / SUM(pass_att)) - 0.3) / 0.2, 0), 2.375)
+ LEAST(GREATEST(((SUM(pass_yds) / SUM(pass_att)) - 3.0) / 4.0, 0.0), 2.375)
+ LEAST(GREATEST( (SUM(pass_td) / SUM(pass_att)) / 0.05, 0.0), 2.375)
+ LEAST(GREATEST((0.095 - (SUM(pass_int) / SUM(pass_att))) / 0.04, 0.0), 2.375)
),
1), NULL
)
as pass_rating_csk, SUM(pass_yds IS NULL)+SUM(pass_att IS NULL)+SUM(pass_td IS NULL)+SUM(pass_cmp IS NULL)+SUM(pass_int IS NULL) as pass_rating_incomplete, ROUND(IF(SUM(pass_att),
ROUND(100 *
(1.0 / 6.0) *
(LEAST(GREATEST(((SUM(pass_cmp) / SUM(pass_att)) - 0.3) / 0.2, 0), 2.375)
+ LEAST(GREATEST(((SUM(pass_yds) / SUM(pass_att)) - 3.0) / 4.0, 0.0), 2.375)
+ LEAST(GREATEST( (SUM(pass_td) / SUM(pass_att)) / 0.05, 0.0), 2.375)
+ LEAST(GREATEST((0.095 - (SUM(pass_int) / SUM(pass_att))) / 0.04, 0.0), 2.375)
),
1), NULL
),
1) AS pass_rating, SUM(pass_sacked IS NULL) as pass_sacked_incomplete, SUM(pass_sacked) AS pass_sacked, SUM(pass_sacked_yds IS NULL) as pass_sacked_yds_incomplete, SUM(pass_sacked_yds) AS pass_sacked_yds, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL) as pass_sacked_pct_csk, SUM(pass_att IS NULL)+SUM(pass_sacked IS NULL) as pass_sacked_pct_incomplete, ROUND(100 * (IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_sacked))/SUM(IF(pass_sacked IS NULL,0,pass_att+pass_sacked)) , NULL)),2) AS pass_sacked_pct, IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL) as pass_yds_per_att_csk, SUM(pass_att IS NULL)+SUM(pass_yds IS NULL) as pass_yds_per_att_incomplete, ROUND(IF(SUM(pass_att), (SUM(pass_yds)/SUM(pass_att)), NULL),1) AS pass_yds_per_att, IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL) as pass_adj_yds_per_att_csk, SUM(pass_int IS NULL)+SUM(pass_td IS NULL)+SUM(pass_att IS NULL)+SUM(pass_yds IS NULL) as pass_adj_yds_per_att_incomplete, ROUND(IF(SUM(pass_att),(SUM(pass_yds) + 20.0 * SUM(pass_td) - 45.0 * SUM(pass_int))/SUM(pass_att),NULL),2) AS pass_adj_yds_per_att, IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL) as pass_adj_net_yds_per_att_csk, SUM(pass_td IS NULL)+SUM(pass_sacked_yds IS NULL)+SUM(pass_att IS NULL)+SUM(pass_yds IS NULL)+SUM(pass_int IS NULL)+SUM(pass_sacked IS NULL) as pass_adj_net_yds_per_att_incomplete, ROUND(IF(SUM(pass_sacked IS NOT NULL)>0,SUM(IF(pass_sacked IS NULL,0,pass_yds-pass_sacked_yds + (20.0 * pass_td) - (45.0 * pass_int)))/SUM(IF(pass_sacked IS NULL,0,pass_sacked+pass_att)) ,NULL),2) AS pass_adj_net_yds_per_att, IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL) as pass_yds_per_cmp_csk, SUM(pass_yds IS NULL)+SUM(pass_cmp IS NULL) as pass_yds_per_cmp_incomplete, ROUND(IF(SUM(pass_cmp), SUM(pass_yds)/SUM(pass_cmp), NULL),1) AS pass_yds_per_cmp
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="post"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
Table Build Time: 0.08 seconds
Table Build Time: 0.05 seconds
--------------------------------------
sum_rec
Page Setup Time: 0.00079 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(rush_att IS NULL) as rush_att_incomplete, SUM(rush_att) AS rush_att, SUM(rush_yds IS NULL) as rush_yds_incomplete, SUM(rush_yds) AS rush_yds, IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL) as rush_yds_per_att_csk, SUM(rush_att IS NULL)+SUM(rush_yds IS NULL) as rush_yds_per_att_incomplete, ROUND(IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL),1) AS rush_yds_per_att, SUM(rush_td IS NULL) as rush_td_incomplete, SUM(rush_td) AS rush_td, SUM(rush_first_down IS NULL) as rush_first_down_incomplete, SUM(rush_first_down) AS rush_first_down
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="reg"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(rush_att IS NULL) as rush_att_incomplete, SUM(rush_att) AS rush_att, SUM(rush_yds IS NULL) as rush_yds_incomplete, SUM(rush_yds) AS rush_yds, IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL) as rush_yds_per_att_csk, SUM(rush_att IS NULL)+SUM(rush_yds IS NULL) as rush_yds_per_att_incomplete, ROUND(IF(SUM(rush_att), SUM(rush_yds)/SUM(rush_att), NULL),1) AS rush_yds_per_att, SUM(rush_td IS NULL) as rush_td_incomplete, SUM(rush_td) AS rush_td, SUM(rush_first_down IS NULL) as rush_first_down_incomplete, SUM(rush_first_down) AS rush_first_down
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="post"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
Table Build Time: 0.07 seconds
Table Build Time: 0.05 seconds
--------------------------------------
sum_kick
Page Setup Time: 0.01849 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(xpm IS NULL) as xpm_incomplete, SUM(xpm) AS xpm, SUM(xpa IS NULL) as xpa_incomplete, SUM(xpa) AS xpa, IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL) as xp_pct_csk, SUM(xpm IS NULL)+SUM(xpa IS NULL) as xp_pct_incomplete, ROUND(100 * (IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL)),1) AS xp_pct, SUM(fgm IS NULL) as fgm_incomplete, SUM(fgm) AS fgm, SUM(fga IS NULL) as fga_incomplete, SUM(fga) AS fga, IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL) as fg_pct_csk, SUM(fgm IS NULL)+SUM(fga IS NULL) as fg_pct_incomplete, ROUND(100 * (IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL)),1) AS fg_pct, SUM(two_pt_md IS NULL) as two_pt_md_incomplete, SUM(two_pt_md) AS two_pt_md, SUM(punt IS NULL) as punt_incomplete, SUM(punt) AS punt, SUM(punt_yds IS NULL) as punt_yds_incomplete, SUM(punt_yds) AS punt_yds, IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL) as punt_yds_per_punt_csk, SUM(punt IS NULL)+SUM(punt_yds IS NULL) as punt_yds_per_punt_incomplete, ROUND(IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL),1) AS punt_yds_per_punt, SUM(punt_blocked IS NULL) as punt_blocked_incomplete, SUM(punt_blocked) AS punt_blocked
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="reg"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(xpm IS NULL) as xpm_incomplete, SUM(xpm) AS xpm, SUM(xpa IS NULL) as xpa_incomplete, SUM(xpa) AS xpa, IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL) as xp_pct_csk, SUM(xpm IS NULL)+SUM(xpa IS NULL) as xp_pct_incomplete, ROUND(100 * (IF(SUM(xpa), SUM(IF(IFNULL(xpa,0),xpm,0))/SUM(IF(IFNULL(xpa,0),xpa,0)), NULL)),1) AS xp_pct, SUM(fgm IS NULL) as fgm_incomplete, SUM(fgm) AS fgm, SUM(fga IS NULL) as fga_incomplete, SUM(fga) AS fga, IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL) as fg_pct_csk, SUM(fgm IS NULL)+SUM(fga IS NULL) as fg_pct_incomplete, ROUND(100 * (IF(SUM(fga), SUM(IF(IFNULL(fga,0),fgm,0))/SUM(IF(IFNULL(fga,0),fga,0)), NULL)),1) AS fg_pct, SUM(two_pt_md IS NULL) as two_pt_md_incomplete, SUM(two_pt_md) AS two_pt_md, SUM(punt IS NULL) as punt_incomplete, SUM(punt) AS punt, SUM(punt_yds IS NULL) as punt_yds_incomplete, SUM(punt_yds) AS punt_yds, IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL) as punt_yds_per_punt_csk, SUM(punt IS NULL)+SUM(punt_yds IS NULL) as punt_yds_per_punt_incomplete, ROUND(IF(SUM(punt), SUM(punt_yds)/SUM(punt), NULL),1) AS punt_yds_per_punt, SUM(punt_blocked IS NULL) as punt_blocked_incomplete, SUM(punt_blocked) AS punt_blocked
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="post"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
Table Build Time: 0.08 seconds
Table Build Time: 0.04 seconds
--------------------------------------
sum_return
Page Setup Time: 0.00109 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(kick_ret IS NULL) as kick_ret_incomplete, SUM(kick_ret) AS kick_ret, SUM(kick_ret_yds IS NULL) as kick_ret_yds_incomplete, SUM(kick_ret_yds) AS kick_ret_yds, IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL) as kick_ret_yds_per_ret_csk, SUM(kick_ret IS NULL)+SUM(kick_ret_yds IS NULL) as kick_ret_yds_per_ret_incomplete, ROUND(IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL),1) AS kick_ret_yds_per_ret, SUM(kick_ret_td IS NULL) as kick_ret_td_incomplete, SUM(kick_ret_td) AS kick_ret_td, SUM(punt_ret IS NULL) as punt_ret_incomplete, SUM(punt_ret) AS punt_ret, SUM(punt_ret_yds IS NULL) as punt_ret_yds_incomplete, SUM(punt_ret_yds) AS punt_ret_yds, IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL) as punt_ret_yds_per_ret_csk, SUM(punt_ret IS NULL)+SUM(punt_ret_yds IS NULL) as punt_ret_yds_per_ret_incomplete, ROUND(IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL),1) AS punt_ret_yds_per_ret, SUM(punt_ret_td IS NULL) as punt_ret_td_incomplete, SUM(punt_ret_td) AS punt_ret_td
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="reg"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(kick_ret IS NULL) as kick_ret_incomplete, SUM(kick_ret) AS kick_ret, SUM(kick_ret_yds IS NULL) as kick_ret_yds_incomplete, SUM(kick_ret_yds) AS kick_ret_yds, IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL) as kick_ret_yds_per_ret_csk, SUM(kick_ret IS NULL)+SUM(kick_ret_yds IS NULL) as kick_ret_yds_per_ret_incomplete, ROUND(IF(SUM(kick_ret), SUM(kick_ret_yds)/SUM(kick_ret), NULL),1) AS kick_ret_yds_per_ret, SUM(kick_ret_td IS NULL) as kick_ret_td_incomplete, SUM(kick_ret_td) AS kick_ret_td, SUM(punt_ret IS NULL) as punt_ret_incomplete, SUM(punt_ret) AS punt_ret, SUM(punt_ret_yds IS NULL) as punt_ret_yds_incomplete, SUM(punt_ret_yds) AS punt_ret_yds, IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL) as punt_ret_yds_per_ret_csk, SUM(punt_ret IS NULL)+SUM(punt_ret_yds IS NULL) as punt_ret_yds_per_ret_incomplete, ROUND(IF(SUM(punt_ret), SUM(punt_ret_yds)/SUM(punt_ret), NULL),1) AS punt_ret_yds_per_ret, SUM(punt_ret_td IS NULL) as punt_ret_td_incomplete, SUM(punt_ret_td) AS punt_ret_td
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="post"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
Table Build Time: 0.04 seconds
Table Build Time: 0.04 seconds
--------------------------------------
sum_defense
Page Setup Time: 0.00110 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_sacked_opp IS NULL) as pass_sacked_opp_incomplete, SUM(pass_sacked_opp) AS pass_sacked_opp, SUM(tackles_loss IS NULL) as tackles_loss_incomplete, SUM(tackles_loss) AS tackles_loss, SUM(qb_knockdown IS NULL) as qb_knockdown_incomplete, SUM(qb_knockdown) AS qb_knockdown, SUM(pressures IS NULL) as pressures_incomplete, SUM(pressures) AS pressures, SUM(def_int IS NULL) as def_int_incomplete, SUM(def_int) AS def_int, SUM(def_int_td IS NULL) as def_int_td_incomplete, SUM(def_int_td) AS def_int_td, SUM(fumbles IS NULL) as fumbles_incomplete, SUM(fumbles) AS fumbles, SUM(fumbles_rec IS NULL) as fumbles_rec_incomplete, SUM(fumbles_rec) AS fumbles_rec, SUM(fumbles_rec_yds IS NULL) as fumbles_rec_yds_incomplete, SUM(fumbles_rec_yds) AS fumbles_rec_yds, SUM(fumbles_rec_td IS NULL) as fumbles_rec_td_incomplete, SUM(fumbles_rec_td) AS fumbles_rec_td, SUM(fumbles_forced IS NULL) as fumbles_forced_incomplete, SUM(fumbles_forced) AS fumbles_forced
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="reg"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
SELECT (SELECT name_abbr FROM sup_team_seasons WHERE team_id=st.team_id AND sup_team_seasons.year_id=MAX(st.year_id) LIMIT 1) as franch_abbr, team_id, MIN(year_id) as year_min, MAX(year_id) as year_max, SUM(pass_sacked_opp IS NULL) as pass_sacked_opp_incomplete, SUM(pass_sacked_opp) AS pass_sacked_opp, SUM(tackles_loss IS NULL) as tackles_loss_incomplete, SUM(tackles_loss) AS tackles_loss, SUM(qb_knockdown IS NULL) as qb_knockdown_incomplete, SUM(qb_knockdown) AS qb_knockdown, SUM(pressures IS NULL) as pressures_incomplete, SUM(pressures) AS pressures, SUM(def_int IS NULL) as def_int_incomplete, SUM(def_int) AS def_int, SUM(def_int_td IS NULL) as def_int_td_incomplete, SUM(def_int_td) AS def_int_td, SUM(fumbles IS NULL) as fumbles_incomplete, SUM(fumbles) AS fumbles, SUM(fumbles_rec IS NULL) as fumbles_rec_incomplete, SUM(fumbles_rec) AS fumbles_rec, SUM(fumbles_rec_yds IS NULL) as fumbles_rec_yds_incomplete, SUM(fumbles_rec_yds) AS fumbles_rec_yds, SUM(fumbles_rec_td IS NULL) as fumbles_rec_td_incomplete, SUM(fumbles_rec_td) AS fumbles_rec_td, SUM(fumbles_forced IS NULL) as fumbles_forced_incomplete, SUM(fumbles_forced) AS fumbles_forced
FROM sup_team_seasons as st
JOIN sup_phase_seasons USING (year_id, comp_id, phase_id)
WHERE ((team_id=?) OR (team_id=?))
AND type="post"
GROUP BY team_id LIMIT 0, 200
SQL PARAMS -- $VAR1 = [
'pit',
'dal'
];
Query Time: 0.01 seconds
Table Build Time: 0.06 seconds
Table Build Time: 0.04 seconds
--------------------------------------
SH->PARAM -- $VAR1 = {
'team_id2' => 'pit',
'team_id1' => 'dal',
't1yrto' => 2025,
't2yrto' => 2025,
'match' => 'versus_teamvteam'
};
SH->PARAM_NO_DEFAULT -- $VAR1 = {
'match' => 'versus_teamvteam',
'team_id2' => 'pit',
'team_id1' => 'dal'
};
Data coverage:
Player game data: since 1933. Scoring statistics (TD, XP, FG) are complete. Yardage and attempts statistics are nearly complete. Game participation data since 1970.
Player season data: all-time (since 1920). Scoring statistics (TD, XP, FG) are complete all-time. Yardage and attempts statistics were not recorded until 1932. Advanced stats since 2018.
Team Game data: since 1920. Before 1940, only wins, losses, points for, and points allowed are available. Scoring statistics (TD, XP, FG) are complete since 1920. Yardage and attempts statistics are nearly complete since 1933.
Team Season data: since 1940. Scoring statistics (TD, XP, FG) are complete all-time.
Please see our data coverage page for details.

We're Social...for Statheads
Site Last Updated:
Question, Comment, Feedback, or Correction?
Subscribe to our Free Email Newsletter
Do you have a sports website? Or write about sports? We have tools and resources that can help you use sports data. Find out more.