Hosted on SourceForge
and licensed under
Creative Commons GNU GPL.
| Casey Trauer submitted this query on: September 23, 2010 11:52am EDT | |
| TITLE | NHL season schedule |
|---|---|
| SPORTS | Ice Hockey |
| QUERY | SELECT events.event_key, CONVERT_TZ(events.start_date_time, '+00:00', '-04:00') as time, dn_home.full_name as home, dn_away.full_name as visitor FROM events JOIN events_sub_seasons ess ON ess.event_id = events.id JOIN sub_seasons ss ON ss.id = ess.sub_season_id JOIN affiliations_events ae ON ae.event_id = events.id JOIN affiliations a_league ON a_league.id = ae.affiliation_id JOIN participants_events pe_home ON pe_home.event_id = events.id JOIN participants_events pe_away ON pe_away.event_id = events.id JOIN teams t ON t.id = pe_home.participant_id JOIN display_names dn_home ON pe_home.participant_id = dn_home.entity_id JOIN display_names dn_away ON pe_away.participant_id = dn_away.entity_id WHERE ss.sub_season_key = '2010_season_regular' AND a_league.affiliation_key = 'l.nhl.com' AND a_league.affiliation_type = 'league' AND pe_home.alignment = 'home' AND pe_home.participant_type = 'teams' AND pe_away.alignment = 'away' AND pe_away.participant_type = 'teams' AND dn_home.entity_type = 'teams' AND dn_away.entity_type = 'teams' ORDER BY events.start_date_time; |
| DESCRIPTION | Returns a basic season schedule for the whole year for the whole league. |
| DBs TESTED | MySQL |
| ADDITIONAL NOTES | |
"test"